Viewing 15 posts - 2,371 through 2,385 (of 8,731 total)
The out of memory error is most likely returned by SSMS or the client application that you were using. That happens when dealing with large results sets.
Your rewrite is correct,...
August 4, 2016 at 10:50 am
Why don't you simply store it as a date? It'll be more effective than a constraint.
If you seriously need a constraint, check the following article: http://www.sqlservercentral.com/articles/T-SQL/130558/
August 4, 2016 at 10:44 am
Ray K (8/4/2016)
Grumpy DBA (8/4/2016)
crookj (8/4/2016)
Ed Wagner (8/4/2016)
Sergiy (8/3/2016)
Revenant (8/3/2016)
Ray K (8/3/2016)
Luis Cazares (8/3/2016)
CouplesSingles
Kraft
Sour
Sweet
bitter
IPA
Lager
Ale
August 4, 2016 at 9:10 am
Good, but do you understand how it works?
August 4, 2016 at 8:54 am
Do you need something like this?
WITH CTE AS(
SELECT * , ROW_NUMBER() OVER (PARTITION BY IDENTIFICATION_CODE ORDER BY VERSION_NO DESC) rn
FROM [MY_TABLE]
)
SELECT UNIQUE_ROW_ID
...
August 4, 2016 at 8:29 am
gfx99ne (8/4/2016)
August 4, 2016 at 8:22 am
What about using an OR?
select c1,c2,c3 From numbers
where c3 <> 'CP-961080'
OR c3 is null
August 4, 2016 at 7:48 am
Don't convert your dates into strings just to convert them again back to dates.
Send the variables as parameters in the dynamic query. You just need to use sp_executesql
Here's a cleaner...
August 4, 2016 at 7:11 am
mw112009 (8/3/2016)
I am pleased with the reply from Luis Cazares (8/1/2016).That works fine for me.
No need to reply to this post anymore.
Thanks for stopping by
You should also try...
August 3, 2016 at 2:04 pm
whereisSQL? (8/3/2016)
Ed Wagner (8/3/2016)
Hugo Kornelis (8/3/2016)
Ed Wagner (8/3/2016)
djj (8/3/2016)
whereisSQL? (8/3/2016)
crookj (8/3/2016)
Ed Wagner (8/3/2016)
Y.B. (8/3/2016)
Luis Cazares (8/3/2016)
Hugo Kornelis (8/3/2016)
Ed Wagner (8/3/2016)
crookj (8/3/2016)
djj (8/3/2016)
Grumpy DBA (8/3/2016)
djj (8/3/2016)
Ed Wagner (8/2/2016)
AudienceMob
Mafia
Made
Created
Born
This way
Out
Side
Winder
(black) Mamba
Venom
Spiderman
Arachnophobia
Hippopotomonstrosesquipedaliophobia
Schizophrenia (just...
August 3, 2016 at 2:03 pm
drew.allen (8/3/2016)
Luis Cazares (8/3/2016)
pnr8uk (8/3/2016)
...
August 3, 2016 at 2:01 pm
ntreelevel (8/3/2016)
I have a situation where I should round a col in a table
Ex
Units Desired Result
0.3 ...
August 3, 2016 at 1:55 pm
pnr8uk (8/3/2016)
( 5, Sales5))u(RowId,...
August 3, 2016 at 1:34 pm
pnr8uk (8/3/2016)
This is all I need I...
August 3, 2016 at 10:58 am
Is this what you need? Note that instead of pivot I'm using cross tabs and instead of unpivot I'm using CROSS APPLY.
SELECT RowId,
MAX( CASE WHEN ExSubCat...
August 3, 2016 at 8:48 am
Viewing 15 posts - 2,371 through 2,385 (of 8,731 total)