Viewing 15 posts - 19,726 through 19,740 (of 22,219 total)
abatej (8/14/2008)
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 9:28 am
So change the JOIN on that table to a LEFT JOIN. That means all the data will return from the main table and only those rows that match from the...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 8:15 am
You can make the foreign key non-null, which will force you to have a value, and you can put a unique constraint on the foreign key, making it so only...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 8:10 am
There's do and there's juitsu. The "way" or do study in martial arts is a spiritual excercise. The juitsu or "art" is martial in it's intent. Meaning, we're not so...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 8:08 am
Well, to quote Adam from Myth Busters, "That's your problem, right there."
Relational data storage more or less requires relationships and those are defined through constraints on the tables. Probably, even...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 6:07 am
You also may have columns inside tables with different collation settings. Check that.
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 5:45 am
There's not enough information to answer this question fully. Yes, you need to use JOIN's to put the tables together, but what columns constitute the primary and foreign keys that...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 5:44 am
Rather than changing the locking mechanisms everywhere, I'd strongly suggest looking at the execution plans of the query and the indexes on your tables. Resolve the problems at the root,...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 5:40 am
If my understanding of what you're trying to do is correct, then yeah, I think that's the right code. But please, test it and verify it. Don't simply take my...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 5:35 am
I know Steve emphasized hitting pads as a way to take off the stress, but I don't mind suggesting, if you don't object to a few bruises (and jambed fingers...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 14, 2008 at 5:33 am
If I'm reading this correctly, something like this:
SELECT wcadmin.WTDocumentMaster.WTDocumentNumber AS NUMBER, wcadmin.WTdocument.nameB2folderingInfo AS FOLDER,
...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 13, 2008 at 1:18 pm
Something along these lines should work:
SELECT *
FROM TableA a
WHERE a.Id = (SELECT TOP(1) a2.Id
...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 13, 2008 at 12:50 pm
Are these multi-statement table valued functions? If so, understand that this type of function has not statistics. This means the optimizer treats them like a table that returns one row....
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 13, 2008 at 12:16 pm
If the first guy through creates a plan that uses a scan, unless something fires a recompile of the procedure or the plan ages out of cache, it's going to...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 13, 2008 at 11:36 am
You'll want to rebuild all your indexes and update the space usages after you move it.
But before you move it, use the Upgrade Advisor as mentioned above. There may...
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 13, 2008 at 11:34 am
Viewing 15 posts - 19,726 through 19,740 (of 22,219 total)