Viewing 15 posts - 1 through 15 (of 195 total)
Do you have Query Store enabled for the database(s) you are interested in? sys.dm_exec_query_stats has a column called last_execution_time.
The default for STALE_QUERY_THRESHOLD_DAYS is 30 - so if it has run...
August 4, 2021 at 9:06 am
Drop all the non-clustered indexes then re-create the clustered index with the DROP EXISTING option and use the FILEGROUP name instead of the partition scheme name, and then re-create the...
August 2, 2021 at 3:45 pm
It looks like the query got truncated.... the common-table-expression data does get completed (there is no closing bracket and no other T-SQL statement using it), the rest of the query...
August 2, 2021 at 2:25 pm
It sounds very much like a running total calculation that you want to do therefore I am guessing you need to use SUM with an OVER clause.
August 2, 2021 at 1:21 pm
I would just run DBCC SHRINKFILE(2, 30720)
August 2, 2021 at 12:36 pm
Are you using Visual Studio? You could always use the SQL Server Schema Compare and Data Compare utilities for this, so long as your source database is not too large...
August 2, 2021 at 12:22 pm
I would look at introducing a Conditional Split Transformation between the data source and the destination if you can define appropriate conditions on which to split the data. You can...
August 2, 2021 at 12:16 pm
Have you been able to review the xml_deadlock_report? This will show you the resource involved in the deadlock which might help point you in the right direction.
June 30, 2021 at 8:51 am
Just wondering if it is the column names and the tables they come from you want to find out if you could use a sql parser on the queries you...
June 29, 2021 at 12:57 pm
Do what Grant said!
i.e. start with
select @MaxRows = count(distinct AT.AccountId) from ATable AT
Does that work?
select @MaxRows = count(distinct AT.AccountId) from ATable AT inner...
June 29, 2021 at 8:47 am
Do you have query store enabled? This can be very useful in tracking slow running queries down. I'd also recommend taking a look at Extended Events and setting up traces...
June 29, 2021 at 8:13 am
I would leave the tables and stored procedures in place, unless you know for certain they are not being used. As suggested by others I would script out the jobs...
June 29, 2021 at 8:07 am
I am sure you can do this using sub-reports, you would send the Invoice Number or Order Number value through to the sub-report. I'm also sure you could do this...
June 25, 2021 at 12:39 pm
I have worked with an array of numpties but never used a numpy array.
April 26, 2021 at 1:00 pm
My brain "auto-translated" it to CHAR instead of ASCII, guess that is what it was expecting to see with the numerical values .e.g SELECT CHAR(65),CHAR(66)
April 26, 2021 at 12:54 pm