Subject Re: [firebird-support] What is the fastest form of execution
Author Arno Brinkman
Hi,

> What is the fastest form of execution for a select, and I'm going to throw
a
> union in just to expand the idea a bit...
>
> Select column1, column2, column3
> >From Table1
> Where Column1 = X
> And Column2 = Y
> Union
> Select column1, column2, column3
> >From Table2
> Where Column1 = X
> And Column2 = Y
>
> Question Part 1
>
> You can execute the select as straight SQL, or you can put the select in a
> view, or you can write a stored procedure...so what method would be the
> fastest to slowest...

Just straight SQL should be the fast enough, but a VIEW would be a little
faster.
Also i suggest you using UNION ALL.

Regards,
Arno Brinkman
ABVisie

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird links :
http://www.firebirdsql.com
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/


Nederlandse firebird nieuwsgroep :
news://80.126.130.81