I would like to thank all of you. Although it all sounds logic to me, I was very far from finding the problem alone.
So thanks again, Ran On 5/23/06, Jay Sprenkle <[EMAIL PROTECTED]> wrote:
On 5/23/06, Igor Tandetnik <[EMAIL PROTECTED]> wrote: > > When a new connection is opened, SQLite reads and caches the schema. > Prepare operation uses this cached schema, without reading from disk. > This is why prepare doesn't know that schema has changed. > > It would be pretty pointless to have prepare check for schema changes. > This would incur a disk read, and the schema can very well change again > between prepare and step so this read won't achieve anything. Now, the > first step operation has to perform a disk I/O anyway, in order to > acquire a lock. This is when the schema is checked and, if a change is > detected, the current schema is retrieved and cached for the connection. Learned something important there, thanks Igor!