|Subject||Re: [firebird-support] Re: Performance troubles|
> > Thanks but it doesn't seem to work fast enough. So I keep to theOR that a query is "suboptimal".
> > suggestions.
> > It seems like firebird prefers joins made with explicitely use of
> > rather than the implicit call in my code and the code above.
> Yup, my goal was not about show fastest.
> i wanted to give you some performance triks about FB.
> If a simple query takes some hours, it mean there is index problem
> or too many re-reads over data or index pages.
I believe the query from the original poster means that for each
new value in "contacts", the sub-query is executed because of the
condition in the subquery. Obviously, this is much slowed compared
to a JOIN which is executed once and joins the record streams
depending on the matched rows etc etc...
So, in this particular case, a better query returns the same result.
Database Workbench - tool for InterBase, Firebird, MySQL, Oracle & MS SQL
Database development questions? Check the forum!