[sqlite] Row is not fetched with PRAGMA reverse_unordered_selects=true

2019-05-08 Thread Manuel Rigger
Hi, I discovered another bug that is triggered when "PRAGMA reverse_unordered_selects=true" is used. It's similar to a previous bug that I reported [1], but the statement triggering the bug has a compound expression that should always be true (for values that are not NULL) in the WHERE clause:

Re: [sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Clemens Ladisch
Andrew Moss wrote: > ... an SQLite database hosted on a windows network share (using server > 2012 R2 or later). We are well aware this is not advisable There are three possible sources of network filesystem data corruption: 1) Bad locking implementations. Some Unix-y network filesystems

[sqlite] LIKE does not fetch row when used on INT UNIQUE COLLATE NOCASE column

2019-05-08 Thread Manuel Rigger
Hi, I found an issue where a row is not fetched when using a LIKE operator on an INT UNIQUE COLLATE NOCASE column: CREATE TABLE t0(c0 INT UNIQUE COLLATE NOCASE); INSERT INTO t0(c0) VALUES ('./'); SELECT * FROM t0 WHERE t0.c0 LIKE './'; -- fetches no rows The following query returns TRUE:

Re: [sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Clemens Ladisch
Simon Slavin wrote: > setting the journal mode of the database to WAL will ... certainly lead to data corruption; WAL requires shared memory, which cannot work over a network filesystem. Regards, Clemens ___ sqlite-users mailing list

Re: [sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Warren Young
On May 8, 2019, at 10:30 AM, Jose Isaias Cabrera wrote: > > Warren Young, on Wednesday, May 8, 2019 12:10 PM, wrote... > >> How about you give up on the idea of using Windows shares to distribute a >> SQLite DB >> and use a tool meant for the job, such as BedrockDB? >> >>

Re: [sqlite] Talos Security Advisory for Sqlite3 (TALOS-2019-0777)

2019-05-08 Thread Barry
Dr. Hipp, you're sending your replies to the mailing list as well as your intended recipient. Not sure if this is intended? On Wed, 8 May 2019 at 08:02, Richard Hipp wrote: > On 5/8/19, Richard Hipp wrote: > > On 5/8/19, Regina Wilson (regiwils) wrote: > >> > >> Here’s a copy of the report. >

Re: [sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Jose Isaias Cabrera
Warren Young, on Wednesday, May 8, 2019 12:10 PM, wrote... >On May 8, 2019, at 8:42 AM, Andrew Moss wrote: >How about you give up on the idea of using Windows shares to distribute a >SQLite DB > and use a tool meant for the job, such as BedrockDB? > >https://bedrockdb.com/ Man, I wish this

Re: [sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Warren Young
On May 8, 2019, at 8:42 AM, Andrew Moss wrote: > > We are currently backed into a corner by a customer In what way, exactly? It might help to know. > and are looking at > using an SQLite database hosted on a windows network share (using server > 2012 R2 or later). You’ve fallen victim to the

Re: [sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Simon Slavin
On 8 May 2019, at 3:42pm, Andrew Moss wrote: > My question is, if we limit the application (through other means) to a > single writer, but allow multiple readers, does that remove the risk of > database corruption from multiple SQLite processes? > > Any notes from other users who had to do

Re: [sqlite] Talos Security Advisory for Sqlite3 (TALOS-2019-0777)

2019-05-08 Thread Richard Hipp
On 5/8/19, Richard Hipp wrote: > On 5/8/19, Regina Wilson (regiwils) wrote: >> >> Here’s a copy of the report. > > > Thanks! Is the "poc" file available for our inspection too? If you want to keep the "poc" encrypted, you can log in at https://sqlite.org/secure/upload as user "talos" with

Re: [sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Jose Isaias Cabrera
Andrew Moss, on Wednesday, May 8, 2019 10:42 AM, wrote... >We are currently backed into a corner by a customer and are looking at >using an SQLite database hosted on a windows network share (using server >2012 R2 or later). We are well aware this is not advisable and have read

[sqlite] SQLite with single writer on Windows network share

2019-05-08 Thread Andrew Moss
Hi, We are currently backed into a corner by a customer and are looking at using an SQLite database hosted on a windows network share (using server 2012 R2 or later). We are well aware this is not advisable and have read https://www.sqlite.org/whentouse.html. My question is, if we limit the

Re: [sqlite] Talos Security Advisory for Sqlite3 (TALOS-2019-0777)

2019-05-08 Thread Richard Hipp
On 5/8/19, Regina Wilson (regiwils) wrote: > > Here’s a copy of the report. Thanks! Is the "poc" file available for our inspection too? -- D. Richard Hipp d...@sqlite.org ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org

Re: [sqlite] Talos Security Advisory for Sqlite3 (TALOS-2019-0777)

2019-05-08 Thread Richard Hipp
On 5/8/19, Regina Wilson (regiwils) wrote: > Hello D. Richard Hipp, > > To date, we have not received a response from point of contact handling > security issues. Can you assist with the issues reported via the bug report > site? We don't do PGP here. But you can send unencrypted email

Re: [sqlite] Limiting the result set size at each recursive step in a CTE

2019-05-08 Thread R Smith
On 2019/05/07 7:57 PM, Thomas Zimmermann wrote: Hi! Sometimes it is desirable to limit the size of the queue¹ in a recursive CTE//... CREATE TABLE comment (     comment_id INTEGER PRIMARY KEY,     parent_comment_id INTEGER REFERENCES comment (comment_id),     created_at INTEGER NOT NULL --

Re: [sqlite] [EXTERNAL] If two orders are both the same order?

2019-05-08 Thread Hick Gunter
I take it that AN is the primary key of table ART. The query shown has 2 possible solutions: a) SCAN table ART, then SEARCH table XPOST on (GNAME=?,AN=?,TIME>=?) b) SEARCH table XPOST on (GNAME=?), check if TIME matches, SEARCH table ART on (AN=?) Plan a means a full table scan of ART in the