diff options
author | Daniel Gruno <humbedooh@apache.org> | 2014-02-21 12:10:10 +0100 |
---|---|---|
committer | Daniel Gruno <humbedooh@apache.org> | 2014-02-21 12:10:10 +0100 |
commit | dde9e0effa49543f4b47f4292ea430db733f7357 (patch) | |
tree | c756854d97e447434c77a814f88b23836c2e5a57 /docs/manual/mod/mod_lua.xml | |
parent | remove more backported fixes (diff) | |
download | apache2-dde9e0effa49543f4b47f4292ea430db733f7357.tar.xz apache2-dde9e0effa49543f4b47f4292ea430db733f7357.zip |
Allow mod_lua to supply a database result with named rows instead of only numeric indexes.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1570528 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'docs/manual/mod/mod_lua.xml')
-rw-r--r-- | docs/manual/mod/mod_lua.xml | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/docs/manual/mod/mod_lua.xml b/docs/manual/mod/mod_lua.xml index 3b06d1e563..6f780849d7 100644 --- a/docs/manual/mod/mod_lua.xml +++ b/docs/manual/mod/mod_lua.xml @@ -1208,6 +1208,7 @@ local result, err = db:select(r, "SELECT * FROM `tbl` WHERE 1") local rows = result(0) -- Fetch ALL rows synchronously local row = result(-1) -- Fetch the next available row, asynchronously local row = result(1234) -- Fetch row number 1234, asynchronously +local row = result(-1, true) -- Fetch the next available row, using row names as key indexes. </highlight> <p>One can construct a function that returns an iterative function to iterate over all rows in a synchronous or asynchronous way, depending on the async argument: |