On 9/18/17, David Wellman <[email protected]> wrote:
> sqlite3_step - this one runs the sql, builds an answer set and then returns
> the first row

No.  sqlite3_step() does not "build the answer set".  It only begins
computing the answer, stopping at the first row.  The sqlite3_step()
routine has no idea how many more rows will follow at that point.

The only way to find out how many rows there are in the answer set is
to run sqlite3_step() repeatedly and count the number of times it
returns SQLITE_ROW before returning SQLITE_DONE.

-- 
D. Richard Hipp
[email protected]
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to