stmt:urows

Creates an iterator that returns the rows from a SELECT

Prototype

stmt:urows()

Description

Returns an function that iterates over the values of the result set of statement stmt. Each iteration returns the values for the current row. This is the prepared statement equivalent of db:urows().


Note: You should let the iterator finish (that is, get to the end of the selected rows) otherwise the database remains locked. So, do not "break" out of the for loop.

Lua functions

Topics