On 25 Apr 2013, at 1:58pm, Clemens Ladisch <clem...@ladisch.de> wrote:

>  SELECT id
>  FROM pointslocation
>  WHERE id IN (1,7,3,4,5,2,6)
>  ORDER BY CASE id
>           WHEN 1 THEN 1
>           WHEN 7 THEN 2
>           WHEN 3 THEN 3
>           WHEN 4 THEN 4
>           WHEN 5 THEN 5
>           WHEN 2 THEN 6
>           WHEN 6 THEN 7
>           END

Clever.  Could generate that clause in code.

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

Reply via email to