Yuanzhong Xu wrote:
> There is a related issue:
>
> If you use this valid efficient query as a subquery of SELECT id FROM (...), 
> i.e.,
>
> SELECT id FROM (SELECT id,data FROM (SELECT * FROM t1 UNION ALL SELECT
> * FROM t2) WHERE id=10 ORDER BY data);
>
> SQLite reports error:
> Error: 1st ORDER BY term out of range - should be between 1 and 1

This is a bug in SQLite.

Minimum example to reproduce this:

  create table t(x);
  select x from (select 42, x from (select x from t union all select x from t) 
order by x);


Regards,
Clemens
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to