SELECT t.*
FROM unnest(ARRAY[1,2,3,2,3,5]) item_id
LEFT JOIN items t on t.id=item_id
A consulta acima seleciona itens de
items
tabela com ids:1,2,3,2,3,5 nessa ordem. SELECT t.*
FROM unnest(ARRAY[1,2,3,2,3,5]) item_id
LEFT JOIN items t on t.id=item_id
items
tabela com ids:1,2,3,2,3,5 nessa ordem.