[prev in list] [next in list] [prev in thread] [next in thread] 

List:       sqlite-users
Subject:    Re: [sqlite] Equivalent syntax in sqlite
From:       J Decker <d3ck0r () gmail ! com>
Date:       2017-04-27 2:55:08
Message-ID: CAA2GJqXxEgS=uXqCz+xSzgz=VDp7c8AEFj8Xhmi8CJjvG3Q3Vg () mail ! gmail ! com
[Download RAW message or body]

If you change from an auto increment to a GUID/UUID  you can simply use
'REPLACE INTO' and you don't have to worry about the select, because you'll
already know the ID.

http://www.sqlitetutorial.net/sqlite-replace-statement/



On Wed, Apr 26, 2017 at 4:05 PM, Joseph L. Casale <jcasale@activenetwerx.com
> wrote:

> From: sqlite-users [mailto:sqlite-users-bounces@mailinglists.sqlite.org]
> On
> Behalf Of David Raymond
> Sent: Wednesday, April 26, 2017 3:00 PM
> To: SQLite mailing list <sqlite-users@mailinglists.sqlite.org>
> Subject: Re: [sqlite] Equivalent syntax in sqlite
>
> > With the comment that the insert or ignore method there will only work if
> > there's an explicit unique constraint on your given criteria.
>
> Yup, the table does have one. Thanks for the help guys.
> jlc
> _______________________________________________
> 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

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic