View previous topic :: View next topic
|
Author |
Message |
rajandhla
Active User
Joined: 18 Oct 2005 Posts: 182 Location: Luton UK
|
|
|
|
Hi Guys,
with your experience can you please let me the answers for the below queries
1. If i reduce the lists of columns in the select clause in a query does it alter the performance (incerease/decrease)
2. Instead of LIKE if a use IN for a where clause will effect performance
(incerease/decrease)
Regards,
Jayaram |
|
Back to top |
|
|
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
rajandhla wrote: |
1. If i reduce the lists of columns in the select clause in a query does it alter the performance (incerease/decrease) |
No, it should not.
Quote: |
2. Instead of LIKE if a use IN for a where clause will effect performance (incerease/decrease) |
It depends upon the indexes. |
|
Back to top |
|
|
rajandhla
Active User
Joined: 18 Oct 2005 Posts: 182 Location: Luton UK
|
|
|
|
Thanks For the prompt reply.........
One more query...
If i use relational operator instead of NOT NULL in where clause will it effect performance.....
ex : Instead of A is not NULL if i use A>0 will it effect performance |
|
Back to top |
|
|
vini_srcna
Active User
Joined: 26 May 2005 Posts: 178 Location: Copenhagen, Denmark
|
|
|
|
Quote: |
1. If i reduce the lists of columns in the select clause in a query does it alter the performance (incerease/decrease) |
I would say it will increase the performance(depends on how much data you are dealing with and the logic involved in the query). No need to fetch additional columns.
2. LIKE is used when you know the solution partially. Probably this will scan and read more values. IN is used when you know the full value. If that is a indexed column IN should increase the peroformance.
3. Once again performance does not depends on what values does A contain. It doesn't matter. It depends whether you query is going for Index scan or tablespace scan or something like that. |
|
Back to top |
|
|
Suryanarayana.tadala
New User
Joined: 03 Nov 2005 Posts: 43 Location: St.Louis
|
|
|
|
I would say performance increases on the volume of data you are dealing with and the business that the query has ...but to be straight enough it woud be Yes Performance increases
2.Yes Performace is increased...
3. It depends whether you query is going for Index scan or tablespace scan or something like that. |
|
Back to top |
|
|
|