Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

SQL Query Timed Out Expand / Collapse
Author
Message
Posted Monday, September 24, 2012 8:20 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Monday, September 24, 2012 9:17 AM
Points: 2, Visits: 12
Hi

We are looking to upgrade our current SQL and Server, at the minute a lot of our larger tables (2-3 million rows) are timing out when I attempt to do simply queries such as selecting the transactions from the current year. We currently have a 6 year old server, could the timing out be due to the number of the rows? I have just looked and the server only has 4 GB of RAM would increasing this allow for more Memory to process the query as well as the whole running of the server? Or would it be simpier and more effective to get a new Server and keep the old as a backup or File Server?

Thanks for any advice offered.
Post #1363515
Posted Monday, September 24, 2012 8:33 AM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Today @ 12:04 PM
Points: 13,239, Visits: 12,081
martin 81121 (9/24/2012)
Hi

We are looking to upgrade our current SQL and Server, at the minute a lot of our larger tables (2-3 million rows) are timing out when I attempt to do simply queries such as selecting the transactions from the current year. We currently have a 6 year old server, could the timing out be due to the number of the rows? I have just looked and the server only has 4 GB of RAM would increasing this allow for more Memory to process the query as well as the whole running of the server? Or would it be simpier and more effective to get a new Server and keep the old as a backup or File Server?

Thanks for any advice offered.


The hardware MAY be some of the issue but there are a lot of other things involved here. You say "selecting the transactions from the current year", this indicates your query has a where clause. Now we have a whole new realm of possible reasons for performance degradation. We have indexes, SARGability, statistics etc etc etc to think about. Throwing hardware at performance issues will possibly get you some short term gains but it is a long term loss. You need to fix the underlying issues.

See Gail's post here about how to post performance problems. http://www.sqlservercentral.com/articles/SQLServerCentral/66909/


_______________________________________________________________

Need help? Help us help you.

Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

Need to split a string? Try Jeff Moden's splitter.

Cross Tabs and Pivots, Part 1 – Converting Rows to Columns
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs
Understanding and Using APPLY (Part 1)
Understanding and Using APPLY (Part 2)
Post #1363528
Posted Monday, September 24, 2012 11:09 AM


SSCoach

SSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoach

Group: General Forum Members
Last Login: Today @ 9:15 AM
Points: 15,622, Visits: 28,006
It's hard to make real substantive suggestions based on general information. Bigger, faster hardware always helps some. Depending on how much you upgrade the hardware, you can mask really bad problems with T-SQL or database design. But usually, tuning the code and structures are the easiest way to maximize throughput of the system. If you're just getting started with query tuning, I'd suggest getting a copy of my book linked below.

----------------------------------------------------
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood..." Theodore Roosevelt
The Scary DBA
Author of: SQL Server 2012 Query Performance Tuning
SQL Server 2008 Query Performance Tuning Distilled
and
SQL Server Execution Plans

Product Evangelist for Red Gate Software
Post #1363637
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse