通过TFDSQLiteSecurity可以对数据库进行加密处理:
with sqlSecurity do begin Database := 'x:\path_to_database\db.sdb'; Password := 'p@ssword'; ToPassword := 'p@ssword_changed'; case rgSecActions.ItemIndex of//是一个radiogroup C_SET_PASSWORD: SetPassword;//0 C_REMOVE_PASSWORD: RemovePassword;//1 C_CHANGE_PASSWORD: ChangePassword;//2 end; end;
通过TFDSQLiteValidate可以对数据库进行检查、分析和空间清理。
with sqlValidate do begin Database := 'x:\path_to_database\db.sdb'; Password := 'p@ssword'; case rgValActions.ItemIndex of C_ANALYZE: Analyze; C_CHECKONLY: if not CheckOnly then Memo1.Lines.Add('Database has problems !') else Memo1.Lines.Add('Database is valid'); C_SWEEP: Sweep; end; end;
通过 TFDSQLiteBackup可以对数据库进行备份操作。
with sqlBackup do begin Database := 'x:\path_to_database\db.sdb'; DestDatabase := 'x:\path_to_database\db.backup'; Password := 'p@ssword'; DestPassword := 'dest_p@ssword'; Backup; end;
标签:end,Database,ssword,数据库,管理,db,database,path From: https://www.cnblogs.com/luohq001/p/16914107.html