Viewing 15 posts - 1 through 15 (of 22 total)
Understood. I knew what your perspective was. I was a bit concerned that you might not know what others are doing with their queries. I also don't know what...
January 17, 2020 at 1:49 am
Hmm, maybe I misunderstand, I thought the OP said that it was just that one query for the max date, ~ every hour, in order to provide that value...
January 16, 2020 at 8:47 pm
I'd probably just add a trigger to the table to capture the max value(s) in a separate table so that it was always available. All you have to check...
January 16, 2020 at 8:46 pm
A question to be answered is this: How wide is each row of data? This will impact the number of rows of data in each data page. The fewer...
January 16, 2020 at 8:43 pm
Thanks everyone for all the responses and good information. I'm sorry I haven't been able to keep up with them. Let me try clarify a few things quickly.
There are 24...
January 16, 2020 at 5:58 pm
Thanks everyone. I have added a clustered primary key in our test environment but can't compare the performance as the configuration is totally different. When I do the 300 million...
January 15, 2020 at 11:01 pm
Execution plan is attached.
January 15, 2020 at 9:02 pm
Sorry, I am curious as to how it can do this and what factors influence it; I would like to know when indexes are needed for these types of queries.
January 15, 2020 at 8:37 pm
The slight extra space is to store the upper level(s) (root level and intermediate level(s)) of the index, which are the b-tree structure that allows quick searches to specific...
January 8, 2020 at 5:23 pm
Also, in SQL Server, when you're looking at a clustered index, remember, that's the table. The data is stored with the clustered index. There isn't any kind of separation...
January 8, 2020 at 3:34 pm
January 7, 2020 at 8:29 pm
Thanks everyone. I can post more details later, but here are some quick comments/questions:
Good to know about compute scalars, I was wondering what that meant.
What do you...
March 17, 2016 at 9:36 am
Thanks, yes, I updated statistics. In the interest of being able to show it conveniently here I reduced the query down to a very simple example. The original...
March 16, 2016 at 5:36 pm
Here's what I do:
ALTER PARTITION FUNCTION <function_name>()
SPLIT RANGE (@NewDate)
ALTER PARTITION SCHEME <schema_name>
NEXT USED [PRIMARY]
Prior to that I verify that the partition doesn't already exist, but you may not need to...
July 1, 2015 at 9:33 am
Jeff Moden (6/24/2015)You can make INSERT/SELECT run nearly as fast as SELECT/INTO and you don't need to be in the BULK LOGGED or SIMPLE recovery model. Create your target...
June 24, 2015 at 12:31 pm