Re: [sqlite] How to use WHERE clause in UPSERT's conflict target

2018-06-21 Thread nomad
On Wed Jun 20, 2018 at 05:26:19PM -0400, Richard Hipp wrote: > On 6/20/18, Jonathan Koren wrote: > > > > The grammar & documentation > > shows a WHERE > > clause can be given in the "conflict target" of the UPSERT, but the > > documentation does not

Re: [sqlite] How to use WHERE clause in UPSERT's conflict target

2018-06-20 Thread Richard Hipp
On 6/20/18, Jonathan Koren wrote: > > The grammar & documentation > shows > a WHERE clause can be given in the "conflict target" of the UPSERT, but the > documentation does not explain how the result of this clause impacts the > statement. As a

[sqlite] How to use WHERE clause in UPSERT's conflict target

2018-06-20 Thread Jonathan Koren
Hello sqlite-users, I am trying out the new UPSERT feature introduced in 3.24.0 and ran into something I don't quite understand. First some setup: CREATE TABLE notes( guid TEXT UNIQUE NOT NULL, content TEXT ); INSERT INTO notes (guid, content) VALUES ('a1', 'foo'), ('b2', 'bar')