Gilles Roy <[EMAIL PROTECTED]> wrote:
On Sun, Apr 22, 2007 at 05:33:43PM -0500, P Kishor wrote:
i = 0
foreach row
if currentrow's memberid == 4567373
  print i
  get out of the loop
else
  i++

That is what I want to do. I want to know where the memberid is in the
list (imagine the list was a waiting list or something). Is there not
a way to just get the row number back? Is seems inefficient to have to
allocate all of the memory to hold all of the results and then iterate
through them.

You don't need to allocate any memory nor store any results. Just iterate with sqlite3_step on a prepared statement.

Igor Tandetnik

-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to