After adding simple check to prevent 'out of range' exception
Code: Select all
if (FInitialRowsList.Count > 0) and (FCurrentRowsList.Count > 0) then
got feedback with bit different stacktrace
15:58:07.754 ERROR [00619029] ZAbstractDataset.TZAbstractDataset.InternalUpdate (Line 388, "..\..\src\component\ZAbstractDataset.pas" + 10) + $E
15:58:07.754 ERROR [00543871] ZDbcUtils.RaiseSQLException (Line 339, "..\..\src\dbc\ZDbcUtils.pas" + 3) + $E
15:58:07.754 ERROR [004A7C8D] JclHookExcept.DoExceptNotify (Line 353, "JclHookExcept.pas" + 27) + $0
15:58:07.754 ERROR [004029D9] JclCharsets.JclCharsetInfos (Line 1139, "JclCharsets") + $E
15:58:07.754 ERROR [00402FF5] JclCharsets.@FreeMem (Line 2466, "C:\Delphi7\Source\RTL\sys\system.pas" + 10) + $0
15:58:07.754 ERROR [004043B0] JclUnicode.TObject.FreeInstance (Line 8366, "JclUnicode" + 2) + $2
15:58:07.754 ERROR TDMSQLite.RFObjectModify() RFObj CID=48 ID=11158: EZDatabaseError($0061902E): Row buffer is not assigned
Looks like, it attempts to update previously disposed row.
It take too much time to debug such things on production, so i change to generationg SQL myself instead of by dataset.
Some questions:
- is single TZConnection is thread-safe for multiple TZQuery or TZReadOnlyQuery from different threads?
- what is best practice for accessing SQLite from multiple threads with Zeos?