Viewing 15 posts - 19,621 through 19,635 (of 22,226 total)
Another vote for using the OUTPUT clause. That's incredibly useful for doing exactly what you're asking for.
Also, I wouldn't recommend using @@IDENTITY. @@IDENTITY is not limited by the scope of...
"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
September 10, 2008 at 5:31 am
GilaMonster (9/10/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
September 10, 2008 at 5:18 am
Ah, that's a shortcoming with the tool, not SQL Server. Ummm, you might try associating to the first column and then renaming the association (not sure how to do 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
September 9, 2008 at 12:55 pm
I'd start by attempting to kill the process. That should initiate a rollback, meaning whatever changes that process had been making will go away, but you shouldn't have problems with...
"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
September 9, 2008 at 12:17 pm
The best description of this I've seen is contained in the first two chapters of Itzik Ben-Gan's book, Inside SQL Server 2005: T-SQL Querying.
"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
September 9, 2008 at 12:15 pm
If I understand the question, you simply add the relationship three different times, relating the lookup value to the three different columns individually. It's a fine method.
"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
September 9, 2008 at 12:13 pm
Hooey.
If it's a reporting system, and only a reporting system, you should mark the database itself as read 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
September 9, 2008 at 12:03 pm
Dropping the tables every time and then recreating the entire data set will eventually become much more painful than joining between the tables to move only the new data. For...
"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
September 9, 2008 at 8:44 am
Batch complete and RPC complete measure the time on the SQL Server. They don't, necessarily, include network time. The reason I put a caveat there is because very large data...
"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
September 9, 2008 at 6:48 am
You can't just remove a lock. That's data being manipulated and stopping the manipulation mid-stream will break the integrity of the data in the table, possibly losing that data, 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
September 9, 2008 at 6:42 am
Yeah, MAXDOP has been useful situationally. Although if I see a lot of queries suffering from parallelism, I'll raise the threshold.
"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
September 9, 2008 at 6:07 am
lklein (9/8/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
September 8, 2008 at 8:00 am
lklein (9/5/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
September 8, 2008 at 7:34 am
The rotated 8 is a symbol for infinity. It means that you've defined a one-to-many relationship. That is, one person can have many clothes. But really, in a design of...
"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
September 8, 2008 at 6:10 am
I remain where I was. Any of the hints can be useful in a given situation. My primary issue is when people see it as a general fix or best...
"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
September 8, 2008 at 5:59 am
Viewing 15 posts - 19,621 through 19,635 (of 22,226 total)