Re: [sqlite] sqlite bug? Subquery containing like-expression in where clause with starting '%' returns no rows, but without '%' does

2013-02-03 Thread Keith Medcalf
All that is weird is that SQLite appends a LIMIT 1 to the subquery to ensure it only returns  one row.  This can be seen clearly if you look at the EXPLAIN ouput. Some other SQL engines just explode ... some throw an error. I suppose it all depends on your interpretation of "do as I mean, not

Re: [sqlite] sqlite bug? Subquery containing like-expression in where clause with starting '%' returns no rows, but without '%' does

2013-02-03 Thread Thomas Mittelstaedt
Am Sonntag, den 03.02.2013, 14:00 -0700 schrieb Keith Medcalf: > > SELECT moz_places.id, moz_places.url, moz_places.title, moz_bookmarks.parent > > FROM moz_places, moz_bookmarks > > WHERE moz_places.id = moz_bookmarks.fk > >and moz_bookmarks.parent = (select id > >

Re: [sqlite] sqlite bug? Subquery containing like-expression in where clause with starting '%' returns no rows, but without '%' does

2013-02-03 Thread Keith Medcalf
> SELECT moz_places.id, moz_places.url, moz_places.title, moz_bookmarks.parent > FROM moz_places, moz_bookmarks > WHERE moz_places.id = moz_bookmarks.fk >and moz_bookmarks.parent = (select id > from moz_bookmarks > where

[sqlite] sqlite bug? Subquery containing like-expression in where clause with starting '%' returns no rows, but without '%' does

2013-02-03 Thread Thomas Mittelstaedt
Could this be a bug? SELECT moz_places.id, moz_places.url, moz_places.title, moz_bookmarks.parent FROM moz_places , moz_bookmarks WHERE moz_places.id = moz_bookmarks.fkand moz_bookmarks.parent = (select id from moz_bookmarks where title like '%arbeit%') returns