Welcome
Login  | 
Monday, February 06, 2012
  Search
Performance Tip
Location: BlogsAuthor's Blog    
Posted by: adrian 11/19/2007 5:35 AM

 In the last 24 hours, I've received two e-mails asking about adding performance hints / tips to the new web-site.  I'll add something, but I'll quickly answer the most common way to improve performance in a query: 

If you are having performance problems or a query is using an excessive amount of memory the next tip will help.

QueryADataset does not contain an optimizer. It is not recommended to use CROSS JOINS in your queries, for example,

select * from table1,table2 where table1.id=table2.id AND name like 'bill%'. 

Instead, use an INNER JOIN so that rows are filtered as they are joined:

select * from table2 inner join table2 on table1.id=table2.id where name like 'bill%'

For even better performance, use sub-queries as table sources in an INNER JOIN so that rows are filtered before they are joined.  For example,

select * from (select * from table1 where name like 'bill%') inner join table2 on table1.id=table2.id

Copyright ©2007 Adrian Moore
Permalink |  Trackback

Comments (2)  
dvd ripper confronto    By TrackBack on 6/26/2008 11:53 AM
After retiring I became a OU contract instructor at OKC, I saw first hand how messed up the training program was… There is no incentive even at the acadamy to wash out ANYONE, more than 95% pass, even though we knew that many had no chance in the field. The FAA took out the screen so they could point to their new improved“ success” story in training, when in reality they just shifted the burdon of the screen to the individual facilities. You are so right about the CTI program as well, these poor saps are...
# dvd ripper confronto

www.dvdtocdpro.com    By TrackBack on 6/28/2008 8:12 AM
I held the power button for a few seconds to power up and entered into the exact same rebooting situation I had the other day.
# www.dvdtocdpro.com

Search
Archive
Support

Questions or comments?  Contact the author via e-mail queryadataset@hotmail.com

 
Copyright 2005 - 2012 by QueryADataSet