Keeping a record in view after committing an edit lazarus / 16-Databases ---------------------------------------------------------------------- hakelm · 2018-02-13 20:22 When I edit and commit data in a TDBgrid the TSQLTransaction is closed. Reactivation of the SQLQuery and the SQLTransaction places the focus again on the first field of the first record in the query result. How can I keep the record I edited in view so I can see what I just did i.e. how do I return to the table row I was on? H ---------------------------------------------------------------------- JanRoza · 2018-02-13 20:38 Use commitretaining instead of commit. ---------------------------------------------------------------------- hakelm · 2018-02-13 20:59 Thanks! CommitRetaining did the trick. H ---------------------------------------------------------------------- talorigomat · 2018-02-14 14:36 With the SQLQuery component you can also set the property sqoKeepOpenOnCommit to True which may be a better option.  You can find this under Options on the property tab of the object inspector