Viewing 15 posts - 10,981 through 10,995 (of 49,552 total)
ALTER TABLE <table name> ADD <columnName> ROWVERSION;
Nothing special
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 12, 2013 at 6:02 am
Evaluate how often that table is accessed by the ID column and how often it's accessed by the date column. If it's evaluated by the date far more often, consider...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 12, 2013 at 4:10 am
James_UK_Dev (11/12/2013)
There probably is something in the contract, but no ones ever enforced it as we always end up doing it for good will.
That's probably something you need to address...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 12, 2013 at 3:17 am
CASE wHEN (DATEDIFF(day, A.StartDate, A.EndDate)) = 0 THEN 1 ELSE Sum(A.budgetedTotalWorkload)/ (DATEDIFF(day, A.StartDate, A.EndDate)) END
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 11:43 pm
Don't, it'll have no effect on performance. Stats aren't created or updated until needed.
Do an update with fullscan afterwards, but no need to disable any options.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 10:06 pm
namdinh4 (11/11/2013)
What if multiple columns of the index are not being use?
Same answer.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 2:17 pm
Well of course it'll go for a clustered index scan if there's only a clustered index on the table. There's no other possible method of getting the rows required.
Do you...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 2:17 pm
namdinh4 (11/11/2013)
I would like to know which column of the index being used and how many time it is being referenced.
Index usage is not tracked to the column level.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 2:15 pm
Start by taking out the nolock (unless incorrect results are acceptable) and replacing the * with the specific columns you need. Then post the other indexes the table has (because...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 1:51 pm
You could capture and analyse every single query that executes against that table and test them all out with the narrower index.
Why are you worried about a single column?
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 1:37 pm
I'm 6 years older than you are and I'm on the younger end of the SQL people that I know. Definitely on the younger end of the people at the...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 1:29 pm
Edit: Not sure anymore...
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 1:27 pm
A nonclustered index will always have 0 lookups. Lookups only occur to the clustered index. DMVs track the index usage, nothing tracks usage to the column level.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 1:25 pm
Express12 (11/11/2013)
• Perform Recompile Procs
Not required, waste of time at best.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 8:46 am
Express12 (11/11/2013)
the vendor mandated we set COLLATION to: Latin1_General_BIN
Fire that vendor.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
November 11, 2013 at 8:39 am
Viewing 15 posts - 10,981 through 10,995 (of 49,552 total)