Subject Re: [ib-support] Re: SQL ORDER BY problem
Author lele@seldati.it
>>>>> On Thu, 25 Jul 2002 09:51:38 -0000, "mircostange" <mirco@...> said:

m> Running 2 selects is exactly what I would like to save. But
m> thanks anyway

What about something like

SELECT c1,c2,abs(c2-y)
FROM a
WHERE c1=:x
ORDER BY 3

If c2 is a string, then maybe you can arrange using a strcmp-like
function...

hth, ciao, lele.
--
nickname: Lele Gaifax | Quando vivro' di quello che ho pensato ieri
real: Emanuele Gaifas | comincero' ad aver paura di chi mi copia.
email: lele@... | -- Fortunato Depero, 1929.