Viewing 15 posts - 3,901 through 3,915 (of 7,610 total)
Since you already have an identity column, go ahead and add that to make the clustering unique. SQL would "uniquify" it, but it's better to do it yourself to avoid...
March 15, 2017 at 9:32 am
March 14, 2017 at 4:35 pm
Change the clustering index to the 2 columns that are used most often / nearly always as predicates. If you prefer, you can add a unique column as a 3rd...
March 14, 2017 at 9:14 am
Some things to consider:
Typically you'll most likely access these rows by datetime range. I'm guessing the actual query might even have such a date restriction, or, if it...
March 13, 2017 at 1:32 pm
March 10, 2017 at 9:11 am
March 10, 2017 at 9:02 am
March 10, 2017 at 9:02 am
Wow, that's a huge amount of code. Does it do something better than the code I posted earlier?:
SELECT DT.*,
DATEDIFF(YEAR, LowDate, HighDate) - CASE...
March 9, 2017 at 3:51 pm
Yes, the "SET NOCOUNT ON" should be w/i the trigger code itself:
CREATE TRIGGER trEMCondition_INSERT
ON dbo.vEMLocationHistory
AFTER INSERT
AS
SET NOCOUNT ON;
UPDATE e
March 9, 2017 at 3:25 pm
I'd have to see the specific code, but it appears the GROUP BY is not complete/correct:
SELECT
ID, NAME,
MAX(CASE WHEN TestType.id = 1 THEN Testing.score END) AS Reading,
March 9, 2017 at 1:19 pm
More than 50% of the time, identity is the wrong clustering key, because there's another column(s) that is(are) more valuable overall as the one and only clustering key. The single...
March 9, 2017 at 11:53 am
Viewing 15 posts - 3,901 through 3,915 (of 7,610 total)