Viewing 15 posts - 6,406 through 6,420 (of 7,616 total)
Are schema names specified on the tables in the query? If not, what are the default schemas of the two users running the queries?
September 4, 2013 at 3:17 pm
You're quite right. There's no genuinely good reason for the "default" clustering key to be an identity column. Many people just do it by rote, without thinking about...
September 4, 2013 at 3:14 pm
SELECT
[Database],
MAX(CASE WHEN MONTH(ReportDate) = 01 THEN Size END) AS Jan,
MAX(CASE WHEN MONTH(ReportDate) = 02 THEN Size END) AS...
September 4, 2013 at 2:11 pm
Patti Johnson (9/4/2013)
IF DATABASEPROPERTYEX('archer', 'Status') = 'ONLINE'
AND EXISTS(SELECT 1 FROM sys.database_mirroring WHERE...
September 4, 2013 at 1:56 pm
Patti Johnson (9/4/2013)
IF DATABASEPROPERTYEX('archer', 'Status') = 'ONLINE'
BEGIN
use archer
SET NOCOUNT ON
END
It looks good until you execute and I...
September 4, 2013 at 1:33 pm
Try this:
IF DATABASEPROPERTYEX('archer', 'Status') = 'ONLINE'
BEGIN
...
END
September 4, 2013 at 12:26 pm
You don't want to use a function against the END_DATETIME column if you can avoid it, since any function will prevent SQL from using the full seek capabilities against that...
September 3, 2013 at 2:10 pm
Don't forget restore damaged instance. That is the most complex recovery. Particularly test for master, model and msdb.
September 3, 2013 at 2:03 pm
Whatever rules you decide on, you should enforce them programmatically. Otherwise, the rules will be broken and be meaningless.
Also, follow the first rule of naming -- don't build meaning...
September 3, 2013 at 2:00 pm
Something like below. It's possible you only need one left join, depending on the specific data in your tables:
SELECT
CASE WHEN b_out.Continent_cd IS NOT NULL THEN...
September 3, 2013 at 1:49 pm
MyDoggieJessie (8/30/2013)
ScottPletcher (8/30/2013)
MyDoggieJessie (8/30/2013)
It may "bypass" the locking of the records it's ready but it does not improve performance or reduce any overhead one bit.
LOL. That's self-contradictory...
August 30, 2013 at 2:49 pm
Sean Lange (8/30/2013)
ScottPletcher (8/30/2013)
Sean Lange (8/30/2013)
ScottPletcher (8/30/2013)
Sean Lange (8/30/2013)
ScottPletcher (8/30/2013)
Sean Lange (8/30/2013)
NOLOCK hints. They are NOT a performance boost.
To me, that's not a logical claim. While NOLOCK is clearly...
August 30, 2013 at 2:23 pm
Sean Lange (8/30/2013)
ScottPletcher (8/30/2013)
NOLOCK can be useful, for example, for code lookup tables, such as state code lookups. A state hasn't been added since 1959, I think I'll risk...
August 30, 2013 at 2:17 pm
Sean Lange (8/30/2013)
ScottPletcher (8/30/2013)
Sean Lange (8/30/2013)
ScottPletcher (8/30/2013)
Sean Lange (8/30/2013)
NOLOCK hints. They are NOT a performance boost.
To me, that's not a logical claim. While NOLOCK is clearly dangerous, it DOES...
August 30, 2013 at 2:02 pm
MyDoggieJessie (8/30/2013)
It may "bypass" the locking of the records it's ready but it does not improve performance or reduce any overhead one bit.
LOL. That's self-contradictory -- if NOLOCK avoids...
August 30, 2013 at 2:00 pm
Viewing 15 posts - 6,406 through 6,420 (of 7,616 total)