Subject Re: [firebird-support] Order by (Date minus Date)
Author Magnus Titho
ai_no_kareshi wrote:
> Greetings, all. Suppose I have a table of time periods which I want to
> order by their length. I am trying to do something like the following,
> which I know does not work:
>
> SELECT P.PeriodName, (P.EndDate - P.StartDate) AS PeriodLength
> FROM Periods P
> ORDER BY 2 DESC
>
Works for me.
Which version do you use?

--
Magnus