In PostgreSQL it is possible to order the results of a query according to a
list of values like below. How would this be best implemented using Sequel
syntax?
select c.*from comments cjoin (
values
(1,1),
(3,2),
(2,3),
(4,4)) as x (id, ordering) on c.id = x.idorder by x.ordering
--
You received this message because you are subscribed to the Google Groups
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.