Viewing 15 posts - 3,301 through 3,315 (of 7,609 total)
June 27, 2018 at 3:51 pm
I would hope that SQL itself would change it to an INNER JOIN when applicable, but it certainly won't hurt to try -- or verify using the query plan that...
June 27, 2018 at 3:31 pm
aftab97 - Wednesday, June 27, 2018 1:39 PMThat's an idea, but the tables are vendor proprietary tables and can't be modified.
Does that...
June 27, 2018 at 2:04 pm
Check to see if the db A on each instance allows cross-database ownership chaining:
SELECT is_db_chaining_on, *
FROM sys.databases
WHERE name IN ('A')
If it's 1, then security...
June 27, 2018 at 9:52 am
We would have to see the tables definition and the query itself to give you a reliable answer here.
June 27, 2018 at 9:46 am
While researching, I read online that unless you are using WITH(TABLOCK) when inserting...
June 26, 2018 at 12:35 pm
Yes, eventually it will get compressed automatically. Although SQL doesn't actually do any page compression until the page gets full.
June 26, 2018 at 10:47 am
Just plain DATEDIFF(DAY, ...) will do that. By definition, DATEDIFF counts the number of times the midnight boundary is reached/crossed between two dates/datetimes.
June 26, 2018 at 10:45 am
DECLARE @CurrentYearStart INT
DECLARE @CurrentYearEnd INT
SET @CurrentYearStart = 201801
SET @CurrentYearEnd = 201805
June 21, 2018 at 3:25 pm
To fix the immediate problem, try running:
DBCC CHECKIDENT ('dbo.CmEvent', RESEED, 55845910)
Better yet, rid yourself of the foolish and damaging myth that all tables should be clustered...
June 21, 2018 at 10:12 am
select top 2 *
from (
select max(u.iduser) iduser, max(u.score)...
June 20, 2018 at 9:31 am
As with any nonclus index, SQL estimating that too many pages will be needed from the nonclus index causes SQL to drop back to just scanning the main table. I...
June 20, 2018 at 9:29 am
June 19, 2018 at 3:12 pm
For the CCI, SQL will effectively have to scan all the rows for every query. If you can a nonclus index, SQL may be able to just do lookups to...
June 19, 2018 at 1:05 pm
Viewing 15 posts - 3,301 through 3,315 (of 7,609 total)