>From: sqlite-users-boun...@sqlite.org
[mailto:sqlite-users->boun...@sqlite.org] On Behalf Of Barton Torbert
>Sent: Tuesday, September 22, 2009 11:07 AM
>To: General Discussion of SQLite Database
>Subject: [sqlite] Update vs Insert
>
>Hello,
>
>I am having problems with the update command (through the interface
>library).  In most databases if you issue an update to a record that
does >not exist, it simply adds a new record.  When I try this in SQLite
I get an >error back.  
>
>Is the SQLite update restricted to a record you know already exists?
>
> 
>
>Bart

You can't do that with an 'update' but you can with 'insert or replace.'
This is true in any SQL driven database, not just SQL.

Logan Ratner | Software Engineer | Gas Chromatographs
Emerson Process Management | 5650 Brittmoore Rd | Houston | TX | 77041 |
USA
T +1 713 839 9656 | F +1 713 827 3807
logan.rat...@emerson.com
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to