Do something like this sqlite3_stmt* pStatement; vector<string> vResults; int nError = sqlite3_prepare_v2(pHandle,"SELECT col1 FROM table",-1,&pStatement,NULL); while (sqlite3_step(pStatement) == SQLITE_ROW) { vResults.push_back((char*)sqlite3_column_text(pStatement, 0)); } sqlite3_finalize(pStatement);
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Juzbrig Sent: 23 July 2008 13:31 To: sqlite-users@sqlite.org Subject: [sqlite] SQLite under c++ Hi. I am new in sqlite (before I have mysql + php experience). I have a question If my DB is alredy open sqlite3* handle; const char* baza = "cols.db3" ; char *zErrMsg = 0; sqlite3_open(test_baza,&handle); How can I get the results of SQL "SELECT * FROM" into a string table or any c++ structure ? sqlite3_exec() doesn't seem to return any strings/chars. If anyone could write me that in code I would be grateful. -- View this message in context: http://www.nabble.com/SQLite-under-c%2B%2B-tp18609682p18609682.html Sent from the SQLite mailing list archive at Nabble.com. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users