Viewing 15 posts - 3,931 through 3,945 (of 7,610 total)
I believe that to index the column, it must be persisted. If it's not persisted already, SQL will persist it when you add the index on it.
March 2, 2017 at 11:30 am
You could instead just change the "ON DELETE" option on the FK. For example, to "tell" SQL to automatically set the referencing key to NULL (of course the referencing column(s)...
March 2, 2017 at 10:15 am
Again, I can imagine very few scenarios where a nonclustered index on a temp table would make real sense, typically that just wastes disk space. Just cluster the table that...
March 1, 2017 at 9:20 am
Yeah, straight forward join, for a relatively small temp table, I'd probably go ahead and recluster it:
CREATE CLUSTERED INDEX CL_HIT_RANGE ON #HIT_RANGE
(
February 28, 2017 at 2:37 pm
For the first part, use a clustered index not a nonclustered index.
Presumably you'd want to changce to cluster on RangeLow, RangeHigh for the part of that code that...
February 28, 2017 at 1:48 pm
1 table : 21 000 000 rows
Which table specifically has 21M rows: tblDE_A10 or tblDE?
February 28, 2017 at 9:58 am
Do you use ArcServe backup? [Or its equivalent, if it's now been bought out by another company.] Somewhere in the mists of my mind I believe some backup package created...
February 27, 2017 at 11:17 am
That is my understanding as well. If the job owner has sysadmin-level authority, then the job runs under the Agent's account.
February 27, 2017 at 9:49 am
I use view:
sys.dm_db_index_operational_stats
for that type of analysis / review on a given table/index.
Be aware, though, of the potential volatility of this data, based on the quote...
February 24, 2017 at 9:32 am
The "best method" depends on how you want to do it. Assuming you want to do it via T-SQL, then maybe something like below (I've omitted any error/missing object checking):
DECLARE...
February 23, 2017 at 11:31 am
In short, yes, ignore "query cost relative to batch". There's no question that the new code is vastly more efficient.
February 23, 2017 at 11:24 am
My best guess is that the value is a pseudo-"Julian" date (as IBM called it), i.e., that the last 3 digits are the relative day number of the year.
February 23, 2017 at 11:22 am
Don't model the code or the logic, model the data. Do logical modeling first, then convert that to a physical model. Don't just start out with a physical...
February 22, 2017 at 3:12 pm
Frankly, the attitude wouldn't bother me so much if what he was posting made sense in the real world. But it just doesn't. Making identifier values character(10) simply because you...
February 22, 2017 at 10:20 am
Why avoid 26 REPLACEs? They perform pretty well; I guess unless maybe you have a huge number of rows?!
February 21, 2017 at 12:43 pm
Viewing 15 posts - 3,931 through 3,945 (of 7,610 total)