Re: [sqlite] using sqlite3_get_table

2011-03-31 Thread Igor Tandetnik
On 3/31/2011 10:27 AM, john darnell wrote: > All I need to do is see how many rows a table has. select count(*) from TableName; > char ***CArray = NULL; > int iRow, iCol; > char **err = NULL; > sqlite3_get_table(db_ptr, "Select * from Admin", CArray,,, err); char** CArray =

Re: [sqlite] using sqlite3_get_table --additional info...

2011-03-31 Thread Michael Steiger
On 31.03.2011 16:30 john darnell said the following: > BTW, if there is a better way to get a row count without using > sqlite3_get_table() that would also work. This will work withput fetching the table dbrc = sqlite3_prepare_v2 (db, "select count(*) from table", -1, , NULL); if

Re: [sqlite] using sqlite3_get_table --additional info...

2011-03-31 Thread Mr. Puneet Kishor
On Mar 31, 2011, at 9:30 AM, john darnell wrote: > BTW, if there is a better way to get a row count without using > sqlite3_get_table() that would also work. maybe I am missing something, but what is wrong with "SELECT Count(*) FROM table"? > >

[sqlite] using sqlite3_get_table --additional info...

2011-03-31 Thread john darnell
BTW, if there is a better way to get a row count without using sqlite3_get_table() that would also work. _ From: john darnell Sent: Thursday, March 31, 2011 9:27 AM To: 'General Discussion of SQLite Database' Subject: using sqlite3_get_table All I

[sqlite] using sqlite3_get_table

2011-03-31 Thread john darnell
All I need to do is see how many rows a table has. I stumbled across this function and used it thusly in my code (I removed the error checking for the sake of brevity): Result = sqlite3_initialize(); sqlite3 *db_ptr; Result = 0; Result = sqlite3_open_v2(DBEnginePath, _ptr,

[sqlite] Using sqlite3_get_table get a row, modifing the row, and then updating the row in the sqlite datatabase obtain from sqlite3_get_table

2005-02-17 Thread Steve Frierdich
I retrieved some rows from a sqlite database using the sqlite3_get_table function. Some of these rows are these are modified. How do I have these rows update the same sqlite database? Is there another sqlite function I can call passing the table that was retrieved from the sqlite3_get_table