Subject RE: [firebird-support] Re: Using VIEW (or not)
Author Riho-Rene Ellermaa
The time went from 9.4 sec to 8.2 - small improvement.
I think it is slow, because when I run the 2 parts of the union
separately (without UNION), then the result is 20 ms.

Any ideas, how to get correct account number without UNION


Riho Ellermaa

> -----Original Message-----
> From: Svein Erling [mailto:svein.erling.tysvaer@...]
> Sent: Tuesday, November 25, 2003 10:53 AM
> To: firebird-support@yahoogroups.com
> Subject: [firebird-support] Re: Using VIEW (or not)
>
> Hi Rino-Rene!
>
> I'm just wondering what happens if you change two lines of
> your view, i.e.
>
> where (account.ibandate<=SDATE or 2=1)
> where (account.ibandate>SDATE or 0=3)
>
> I'm OR-ing to avoid using any SDATE indexes, you don't gain
> anything from using an index when a large porportion of the
> records fulfil your criteria. Though if you are saying that
> selecting 35000 records from the view takes 9 seconds and
> think this is 'very' slow, then I think it may be difficult
> for me to be of much help.
>
> Set
>