I do not have shared-cache mode enabled, or anything else that I can see, other than WAL mode. I am not doing any transactions, so the INSERT and SELECT are self contained transactions. This particular database file is opened using ATTACH rather than sqlite3_open(), and it is attached to the 2 database connections that I have open.
I did another test where I removed the '?' Parameter and the call to seqlite3_bind_int() and just created a SELECT statement with the rowid hard-coded in, like 'SELECT * FROM sessiond WHERE rowid=20;', and that also did not work. So it isn't the sqlite3_bind_int() function that is causing the problem. As as side note, apparently sqlite3_bind_int() inserts a NULL when doing 'WHERE rowid=?" If the rowid you are looking for doesn't exist in the table. I tried several SELECTs (using the same code) with various rowid values, some existent and some not, and for the non existent rowid's sqlite3_bind_int() always inserts a NULL. > On Apr 12, 2019, at 1:38 PM, Simon Slavin <slav...@bigfraud.org> wrote: > > On 12 Apr 2019, at 6:32pm, Jim Dossey <jim.dos...@gmail.com> wrote: > >> It's just when I use 2 different connections that the second connection does >> not see the rowid that was just added. > > Okay, I see you're using WAL mode, and two connections. Have you set up > Shared-Cache Mode or anything else that might 'merge' the two connections ? > > Have you defined any transactions, or are both the INSERT and the SELECT > creating their own transactions ? > _______________________________________________ > sqlite-users mailing list > sqlite-users@mailinglists.sqlite.org > http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users