You are not logged in.
Pages: 1
I wonder why you chose to declare
TSQLRequest = object
TSQLStatementCached = object
this is arcane Object Pascal way of declaring stuff. And it can create issues as well (see http://stackoverflow.com/questions/1013 … bject-type for example).
Can you convert those to
TSQLRequest = class(TObject)
TSQLStatementCached = class(TObject)
this would allow easier control of declaration, feeing, avoid the need to use pointers in the cache, and allow you building (as in my case) global cache for binded statements (not just Json results).
Last edited by gaddlord (2012-01-07 23:10:29)
Offline
This was discussed at least in two topics:
First in favor to object.
And second, yes there are possible problems with them too.
"Uncertainty in science: There no doubt exist natural laws, but once this fine reason of ours was corrupted, it corrupted everything.", Blaise Pascal
Offline
TSQLRequest is just a small record pointing to the SQLite3 handles.
Argument of using a global cache for statements is interesting.
But it will be to use it outside the framework.
For this purpose, you have the SynDBSQLlite3 unit available. See http://blog.synopse.info/post/2011/07/2 … ect-access
Statements are already implemented as classes, use an internal cache, and are of higher level: you could use the same code then switch to Oracle or MSSQL (or any OleDB provider) on need.
TSQLRequest is very low-level. In fact, you should not use The SynSQLite3 unit directly in your applications.
Offline
Pages: 1