It results in a error - it stops parsing the statement at the alias 'a'. It seems simple, but I don't believe it is possible to do this in SQLite. I've tried a dozen common syntax variants used by other databases without success.
Here is the syntax of the SQLite UPDATE statement: sql-statement ::= UPDATE [ OR conflict-algorithm ] [database-name .] table-name SET assignment [, assignment]* [WHERE expr] assignment ::= column-name = expr --- Igor Tandetnik <[EMAIL PROTECTED]> wrote: > Joe Wilson wrote: > > Does anyone know how I might accomplish this in SQLite using a single > > update statement? > > > > -- MySQL > > UPDATE accomodation a, country c > > SET a.country = c.country > > WHERE a.country_id = c.country_id; > > > > -- Oracle > > UPDATE accomodation a > > SET a.country = ( > > SELECT c.country > > FROM country c > > WHERE c.country_id = a.country_id > > ); > > SQLite should support the second syntax. Do you have a problem with it? > > Igor Tandetnik > __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com