I am getting slower performance of select statements in MS SQL. I am
finding select statements in MS SQL are even slower than MS ACCESS. Is
there any way to improve the performance of select statements in MS
SQL by tuning the database of anything else??
Thanks in advance!
HoqueIn article <b1a93c73.0310311931.79d07486@.posting.google.com>,
sohelcsc@.yahoo.com says...
> Hi All,
> I am getting slower performance of select statements in MS SQL. I am
> finding select statements in MS SQL are even slower than MS ACCESS. Is
> there any way to improve the performance of select statements in MS
> SQL by tuning the database of anything else??
> Thanks in advance!
> Hoque
That's a very open question with MANY answers:
Several things come to mind:
Improperly configured drive arrays
Lack of proper indexes or clustered index
TOO MANY indexes
Failure to run a maintenance plan on the tables
Lack of memory or CPU
Improperly coded select statements - never use SELECT *, always specify
the columns you want.
--
--
spamfree999@.rrohio.com
(Remove 999 to reply to me)|||sohelcsc@.yahoo.com (Leader) wrote in message news:<b1a93c73.0310311931.79d07486@.posting.google.com>...
> Hi All,
> I am getting slower performance of select statements in MS SQL. I am
> finding select statements in MS SQL are even slower than MS ACCESS. Is
> there any way to improve the performance of select statements in MS
> SQL by tuning the database of anything else??
> Thanks in advance!
> Hoque
There are things you an do
1. If the query is complex try rewriting the logic of the joins e.g.
instead of selecting from tableA joining on to tableB try the reverse.
2. Avoid using LIKE as this causes a table scan to e performed
3. Have the tables you are using in your query got appropriate
indexes? beware of adding indexes as other parts of your application
may slow down because the system has to maintain an additional index.
4. If it has suitable indexes is the index appropriate for being made
a clustered index? There can only be 1 clustered index on a table
as this determines the physical placement of the rows on the disc.
Also if the index has values inserted anywhere in its expected range
of values updating may be slowed too much.
Just a few ideas
Hope this helps
Duncan|||Not without knowing what you are doing.
Run the query in query analyser and look at the execution plan.
This will tell you which tables are causing the problem and you can
index them or recode the query appropriately.
No comments:
Post a Comment