Re: Is this an SQL parsing / ambiguity bug ?
Richard Hipp <[email protected]> Tue, 10 Mar 2020 09:32:54 -0400
| Newsgroups | gmane.comp.db.sqlite.general |
|---|---|
| Message-ID | <CALwJ=MxDfKLYximNNH1kVy6YqF6vC44odXo+fvVg6Cm9DWp+=w@mail.gmail.com> |
On 3/10/20, Simon Slavin <[email protected]> wrote: > On 9 Mar 2020, at 8:40pm, Vladimir Vysotsky <[email protected]> wrote: > >> sqlite> insert into dst(id) select id from src on conflict do nothing; >> Error: near "do": syntax error > > SQLite does not understand "DO NOTHING". You probably want "ON CONFLICT > IGNORE". I think Vlad is trying to do an upsert, which does have a DO NOTHING syntax that I copied from postgres. The parsing ambiguity that Vlad is complaining about (if I understand him correctly) is documented at the bottom of the upsert page: https://www.sqlite.org/lang_UPSERT.html#parseambig -- D. Richard Hipp [email protected] _______________________________________________ sqlite-users mailing list [email protected] http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users