SQL Performance issue due to different Execution Plan with new data
I’m hoping you all can help us with a strange issue that’s popped up suddenly after ~6 months of development on our DB environment. We've been looking for a solution the past week, but haven’t found...
View ArticleINFORMATIONAL: Update Stats command - With Rowcount and With Pagecount
Hi Everyone,I just wanted to put this out there because I think that this feature is so awesome!The undocumented options of the Update Stats command, WITH ROWCOUNT and WITH PAGECOUNT. Used to trick the...
View ArticleSQL Server 2008 R2 Maintenance Plan
I have a SQL Server 2008R2 server configured that hosts multiple databases. The SQL Server (MSSQLSERVER) service uses a local system account.I attempted to setup a maintenance plan that including a...
View ArticleExisting Table Partition
Hi,We have a existing table and it has two date columns (Datatype - Datetime) and it's very big table and we would like to make a partition table. This is a frequently accessed table. We need partition...
View Articlespid -4 blocking the transactions
Hi All,We encountered a situation today where the spid -4 was blocking the transactions. We're not able to kill it as it was not treated as a valid spid by SQL server. We tried to get the UOW using...
View Articlesqlagent service startup timeout
Hello,We're using SQL enterprise 2000 sp3 with windows server 2003 sp1 and sometimes when we reboot this server, sqlagent service cannot startup(30s timeout) but no any error state out(from sqlserver...
View ArticleCan physical IO under VM be slow but look fast?
Perfmon looks happy, but I get the impression that when my server does physical IO performance suffers even more than I'd expect.I'm in a new shop now where all SQL Servers are running in VMs on...
View Articlesp_trace_gettable error
We have a trace set up to collect long running transaction data. This is part of our admin database and runs on each monitored instance in our environment. We are seeing that while our 2005 instances...
View Articlewhat is io_stall_read_ms really?
When looking at the output of sys.dm_io_virtual_file_stats, when you get an average number per read, what does it even mean? Is it basically the wait time for a read, or is it some special stall time...
View ArticleNew Turkish Currency Symbol
We are having problem storing the new Lira symbol for the turkish currency in our SQL 2008 database.The collation used in Turkish_CI_AS.We have updated our Windows machines but still the currency...
View Articlehow to track down primary key violation problem
We have a specific file from our application that cause PK violation on our SQL 2008 server. I would like to track down what those fields are and I know which DB and table those field resides. The...
View ArticleQuestion about sys.dm_db_index_usage_stats.
Greetings. I'm running this query on a 2008R2 server:select * from sys.dm_db_index_usage_stats where database_id = db_id() and user_seeks = 0 and user_scans = 0 and user_lookups = 0And getting 11...
View ArticleRestore database
Hi All,while am restoring the database, am getting following error like database backup set already exists.my backup version is sql 2000 and am restoring in sql 2008.I checked overwrite option...
View ArticleODBC connection
Hi,Client is installing Crystal Reports on his computer. He needs access to one of database on SQL Server 2008. What is required to establish connection from crystal reports odbc connection to sql...
View ArticleDrop partition
In sqlserver 2005, If i have partitioned my table based on date for each month, how do I drop partitions having data older than 3 months. This is to do the archiving the old data as we don't want old...
View ArticleGetting most_recent_sql_handle from prior session?
Hi, We are migrating a COBOL-DATACOME application to .Net COBOL and SQL Server using MicroFocus. I have been monitoring the queries via using DMVs and and traces. I notice an odd thing once in a...
View ArticleAlways On New Availability Group - Full backup is required
Just trying to create a New Availability Group for AlwaysOn , I see the database is listed, in the status it says: "Full backup is Required. The database is AdventureWorks2012, i have taken a full...
View ArticleFind physical reads
Hi,I want to know following information, how can i get it using SQLServer Queries1. Total physical reads on the database. 2. Total logical reads on the database.3. top 10 tables /indexes based on...
View ArticlePartition table with non-clustered index
Hi,I am in sqlserver 2005 developer edition. I have a table awrard_transaction which has refno column as primary key and has a primary key (unique clustered index on it), index name is...
View ArticleHow to find current statement start time.
If a batch which consists of multiple statements is being executed I can find out the start time for the batch from exec_requests (SELECT start_time FROM sys.dm_exec_requests WHERE session_id = @SPID)...
View Article