i have the following piece of code:
Code: Select all
try
qry := dmAeres.qryUsers;
if not qry.Active then
qry.Active := True;
if not qry.Locate(UA_USERNAME, Username, [loCaseInsensitive]) then begin
qry.Append;
qry.FieldByName(UA_USERNAME).AsString := UserName;
qry.Post;
end;
except
on E: Exception do begin
SKAMessageOk(E.Message);
end;
end;
The code above is what i am used to doing with MSAccess, i found some differences with SQLite, but i do not know what to do in the above.
Do i need to put an Unlock or a Commit after the Post? or should the above be enough.