A connection object should not be copied, they will both hold the same internal connection to sqlite.
I really should add a copy constructor, thanks for reminding me. For now just do sql.open("mk.db"). On Wed, 8 Dec 2004 18:45:17 +0100, ibrahim <[EMAIL PROTECTED]> wrote: > Hello, > > I m new to this mailing list , > > I currently try to add sql lite to a program I m working on > > It is a quizz program , > > And I want the question to be incorporated into a sql lite database to enable > search ...etc.. > > I m download the source code of version 2_8_15 > > And compiled it under Visual Studio .NET 2003 with problems (only warnings ) > > As a wrapper , I choose this one : http://dev.int64.org/sqlite.html > > I compiled the sqllite-plus.lib with no problems > > Run the code samples test-select and test-insert with no problem > > So I tried to add the both lib sqlite.lib and sqllite-plus.lib in my real > project ( windows program ) > > I get a lot of errors , I found that the error was due to runtime library > conflit (Multithread DLL / single threaded) > > So I recompiled the both lib with Multithread DLL runtime ... no > problem > > run the samples test-select and test-insert ... no problem > > So I tried to recompile my real project with the both lib ... no problem > > but when i run the code , I get error at runtime : > > library routine called out of sequence ( from ex.what() ) > > Exception de première chance à 0x77e4d756 dans Quizz.exe:Microsoft C++ > exception: std::runtime_error @ 0x0012fe5c. > HEAP[Quizz.exe]: HEAP: Free Heap block 49d4758 modified at 49d487c after it > was freed > Exception non gérée à 0x77f6f570 dans Quizz.exe:Point d'arrêt utilisateur. > > Here is the code that causes the problem : > > sql = sqlite::connection("mk.db"); > > try { > > sqlite::reader reader=sql.executereader("select * from t_test;"); > > reader.close(); > sql.close(); > } > > catch(exception &ex) { > fprintf(i,"%s\n",ex.what() ); > fflush(i); > } > > When I run it in console program no problem > > But when I run it with my win32 project -> problem > > Any help appreciated > > Thanks in advance > > Nicolas Raby > vmgames > France > > -- Cory Nelson http://www.int64.org