Viewing 15 posts - 1,696 through 1,710 (of 22,224 total)
I assume we're talking about a batch here with multiple statements?
In that case, put Extended Events to work. You can create a session using the sql_statement_completed event for batches, or...
"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
July 29, 2020 at 11:31 am
Nah, interrupt sounds fine. Ha! I'll see what I can do to get that fixed.
BTW, 3rd edition is WAY better than the first two.
"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
July 28, 2020 at 2:20 pm
Changes to the connection strings? ANSI settings? Differences in compiled execution plans? As above, wait statistics?
These are just a few of the possibilities. Also, you running a batch versus your...
"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
July 28, 2020 at 12:10 pm
Tons of stuff is faster in 2017. You should see what happened with 2019. They improved all sorts of stuff even more. It's honestly insane just how much better 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
July 28, 2020 at 12:07 pm
OK. So, with ColNumber as the primary means of accessing the data, probably, and you should test this, not just trust some yahoo on the internet, that's your clustered key...
"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
July 28, 2020 at 10:40 am
Okay, maybe I misunderstood the OP, but I thought from their explanation of the problem that they were trying to use the TOP clause to only get part 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
July 23, 2020 at 2:03 pm
A stored proc would just use the script you have. It'll work.
"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
July 23, 2020 at 2:03 pm
In addition to everything Grant said, and he literally wrote the book on execution plans:
I'd also point out that the ORDER BY dufp.FeatureName will cause a sort 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
July 23, 2020 at 12:24 pm
The key here is the types of queries, not simply should I throw an index on. Columnstore indexes are meant for analytical, aggregation & large scan types of queries. That's...
"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
July 23, 2020 at 12:12 pm
I assume you've tried and the error explained that your column names are not there. You can't create a view based on ad hoc queries because the view definition needs...
"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
July 23, 2020 at 12:08 pm
All the cost is located here: [Excel_DK].[dbo].[Excel_DK].[pk_ID] [DUFP]
The predicate is: [Excel_DK].[dbo].[Excel_DK].[PartNumber] as [DUFP].[PartNumber]=[@partNumber]
Probably need an index on that with some INCLUDE for the other returned columns.
Also, you have three different...
"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
July 22, 2020 at 12:53 pm
Then, ever so strongly, I recommend you pursue other approaches. Partitioning almost never succeeds in improving performance. By almost never, I mean, probably, a 99% failure rate. It's purpose is...
"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
July 22, 2020 at 11:45 am
So, have you and the business worked out your Recovery Time Objective and Recovery Point Objective? If not, go do that first. If so, test this method on a restore....
"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
July 21, 2020 at 11:47 am
Define a role. Put the users in that role. Then GRANT SELECT to the role for the schema in question. You can also grant additional functionality to the role....
"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
July 21, 2020 at 11:43 am
Not really. You have to rebuild the structures. This means data movement. The more data you have to move, the longer it will take.
One possibility would be to snapshot a...
"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
July 21, 2020 at 11:39 am
Viewing 15 posts - 1,696 through 1,710 (of 22,224 total)