Subject Re: [ib-support] selecting max date
Author Robert F. Tulloch
Hi:

> I don't know about the SP being better or worse (at least it is consistent)
> but
> check the index's on the table and the plan the query uses, also put the 5
> year
> window into the subquery(if you dont mind trying to work out logic :-)
> but probably the order by is killing the response

Putting the five year window into the subquery actually slowed
it down from 1.0672 to 2.0385.

Thanks.
Best
regards