[sqlite] how to use sqlite3 in win DDK?

2009-12-04 Thread Mw Mw
sqlite3.lib was made by VC++;and already added to the sources file. TARGETLIBS=sqlite3.lib code: #include #include #include void database() { sqlite3 *db; sqlite3_open("c:\\test.db",); DbgPrint("hello,on it\n"); } NTSTATUS DriverEntry(PDRIVER_OBJECT pDriverObj,PUNICODE_STRING

Re: [sqlite] step() fails with SQLITE_BUSY afterBEGINEXCLUSIVETRANSACTION - SOLVED

2009-04-15 Thread mw
Thanks, Ken. I will check that out. -- Mario -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Ken Sent: Wednesday, April 15, 2009 10:13 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] step() fails with

Re: [sqlite] step() fails with SQLITE_BUSY after BEGINEXCLUSIVETRANSACTION - SOLVED

2009-04-15 Thread mw
I've found the problem. It was caused by a pre-compiled statement in a third party library. Since the library was used by several threads now, the statement, compiled in the context of one thread, blocked the entire database when an attempt way made to use it from another thread. The programmer

Re: [sqlite] PRAGMA doesn't support parameter binds?

2009-04-13 Thread mw
How to debug the SQLite amalgation with Visual Studio 2008. To get the debugger going you need to strip out the comments and empty lines from the sqlite.c source file. This can be done easily with two regular expressions for search and replace: First replace (Ctrl+H) (/\*(\n|.)@\*/)|(//.*$)

Re: [sqlite] step() fails with SQLITE_BUSY after BEGIN EXCLUSIVETRANSACTION - SOLVED

2009-04-13 Thread mw
Hi, Marcus I'm absolutely sure that the problem is in my code and not a SQLite problem. SQLite works well in MT, if one respects the documented limits. I just have no handle currently to find the problem. As we all know, Multi-threading is tricky ;-) I will strip down my MT code until I get it

Re: [sqlite] step() fails with SQLITE_BUSY after BEGIN EXCLUSIVETRANSACTION

2009-04-12 Thread mw
Marcus thanks for your suggestions. I have of course checked the obvious things before posting here. Both the BEGIN EXCLUSIVE and the COMMIT return SQLITE_OK. Each thread opens its own db handle with sqlite_open and operates on it. These are completely isolated, they don't know about each

Re: [sqlite] step() fails with SQLITE_BUSY after BEGIN EXCLUSIVETRANSACTION

2009-04-11 Thread mw
Hi, Dave I have read your post. I have also read many of the recent archived posts, and googled the web for hints. I'm at a loss here. The fun thing is that my wrapper class (which I use for a while now in non-MT environments) allows me to track most of what's going on in SQLite. And even that

[sqlite] step() fails with SQLITE_BUSY after BEGIN EXCLUSIVE TRANSACTION

2009-04-11 Thread mw
Hi, I'm using the latest amalgation of sqlite on Windows NTFS, compiled with SQLITE_THREADSAFE=1, from Visual C++. I have two threads which update a database. Each thread uses sqlite_open_v2 to open a connection. Both threads do essentially this: if BEGIN EXCLUSIVE TRANSACTION successful