Viewing 15 posts - 4,321 through 4,335 (of 7,610 total)
TheSQLGuru (4/18/2016)
ScottPletcher (4/18/2016)
TheSQLGuru (4/16/2016)
New rule: YOU WILL, ALWAYS WITHOUT EXCEPTION, USE EXACTLY THE SAME DATA TYPE AS THE COLUMN TO THE BEST OF YOUR LANGUAGES ABILITY TO DO SO!
THAT IS...
April 18, 2016 at 10:25 am
Yeah, definitely not 'sa' or some other existing/standard user.
Create a new user, native SQL user will do if that's available to you, and grant it just the specific permissions it...
April 18, 2016 at 10:14 am
TheSQLGuru (4/16/2016)
New rule: YOU WILL, ALWAYS WITHOUT EXCEPTION, USE EXACTLY THE SAME DATA TYPE AS THE COLUMN TO THE BEST OF YOUR LANGUAGES ABILITY TO DO SO!
THAT IS A HUGE...
April 18, 2016 at 8:48 am
TheSQLGuru (4/15/2016)
ScottPletcher (4/15/2016)
TheSQLGuru (4/15/2016)
ScottPletcher (4/15/2016)
Never use ISNULL in a WHERE or JOIN clause.
Whether the column is nullable or not is irrelevant.
The proper way to code this:
where isnull(SalesOrderID,-1)...
April 15, 2016 at 12:06 pm
dan-572483 (4/15/2016)
Excuse me? Are you saying that if a database is mirrored and disk-level corruption occurs the SQL will just pull the data from the mirror??
And I believe it...
April 15, 2016 at 11:34 am
TheSQLGuru (4/15/2016)
ScottPletcher (4/15/2016)
Never use ISNULL in a WHERE or JOIN clause.
Whether the column is nullable or not is irrelevant.
The proper way to code this:
where isnull(SalesOrderID,-1) = 43665...
April 15, 2016 at 11:15 am
The simplest rules is:
Never use ISNULL in a WHERE or JOIN clause.
Whether the column is nullable or not is irrelevant.
The proper way to code this:
where isnull(SalesOrderID,-1) = 43665 --NEVER!!
is this:
where...
April 15, 2016 at 10:40 am
Triggers should always be written for best efficiency first, even if it makes them harder to understand, especially so in your situation, with such heavy usage.
To keep each trigger as...
April 14, 2016 at 10:29 am
If you just want the static result of a function call to be inserted to the table, use INSERT INTO ... SELECT rather than INSET INTO ... VALUES:
INSERT INTO tblDashboard...
April 13, 2016 at 3:58 pm
No, I don't know what would have added those indexes. But I also don't see the relevance of that. Wouldn't normal index analysis -- of missing index stats,...
April 12, 2016 at 1:02 pm
I think it's a bad idea to assume the existing physical design is correct (unless you know that it was modeled very carefully logically first and then the physical design...
April 11, 2016 at 9:10 am
Or, since we're dealing with JOINs:
What is the difference between INNER JOIN and LEFT OUTER JOIN?
What is the difference between LEFT OUTER JOIN and RIGHT OUTER JOIN?
What is a FULL...
April 8, 2016 at 3:33 pm
Yep, exactly. It sounds like some type of certification q too, where because MS mentions "restricted" in BOL or some other help, you're supposed to remember it exactly and...
April 8, 2016 at 2:37 pm
GonnaCatchIT (4/8/2016)
We run re-indexing and update statistics on daily basis
Is that really necessary? Do you re-index all tables or just those that really need it? Hopefully you don't...
April 8, 2016 at 8:26 am
If the incoming data is sorted in clustering key order, you can add an:
ORDER ( { column [ ASC | DESC ] } [ ,... n ] )
clause to the...
April 7, 2016 at 5:20 pm
Viewing 15 posts - 4,321 through 4,335 (of 7,610 total)