Yes, thanks... it occurred to me that might be the solution after I wrote. I didn't follow up when I realized that the SQLite database module is so different in behavior from the other database modules that I decided to give up and continue using my own SQLite glue.
As a note, I'd suggest that a big flag be put up in the notes about the bundled SQLite module. It returns array(array) instead of array (mapping) from query(), such that it's not possible to use it with any code normally written for databases in Pike. That's certainly fixable, but I don't think it can be fixed in time for this stable release. Perhaps it shouldn't be included/disabled?
Bill
On Jul 22, 2008, at 7:20 PM, Martin Stjernholm, Roxen IS @ Pike developers forum wrote:
Try replacing
if (Pike_sp[0].u.array->size == 0) {
with
if (Pike_sp[-1].u.array->size == 0) {