Viewing 15 posts - 5,821 through 5,835 (of 8,731 total)
Let me see if I understand correctly. You're receiving a comma-delimited parameter and if you have any value different than 0, you'll return a simple result set with no relation...
September 15, 2014 at 4:49 pm
Alexander Suprun (9/15/2014)
ALTER TABLE <YourTableName> ADD ID int NOT NULL IDENTITY (1, 1)ALTER TABLE <YourTableName> ADD CONSTRAINT PK_<YourTableName> PRIMARY KEY (ID)
Alex,
That seems like an easy patch instead of doing a...
September 15, 2014 at 4:00 pm
Could you use the Data Profiling Task in SSIS?
http://msdn.microsoft.com/en-us/library/bb895263(v=sql.105).aspx
September 15, 2014 at 3:26 pm
The following code returns a value of 10. Is that what you're after?
SELECT months_between(TRUNC(TO_DATE( '20131101', 'YYYYMMDD'), 'MM'), TRUNC(SYSDATE, 'MM'))
FROM Dual;
September 15, 2014 at 2:46 pm
Why is it giving a wrong answer? In other words, what would be the correct answer and what are you getting right now?
September 15, 2014 at 2:33 pm
And here you have a different version that will use only the rows needed. Ideally, you shouldn't have to create the PersonList set and you'll have a table with them...
September 15, 2014 at 9:55 am
This might not be the best solution for performance because it will run on all rows. The tricky part is to get the complete list with values in zero for...
September 15, 2014 at 9:47 am
Is this thread full of spam? Or is it a real problem with valid suggestions?
http://www.sqlservercentral.com/Forums/Topic1612977-131-1.aspx
September 12, 2014 at 4:44 pm
I guess I confused what you were trying to say with changing the table you select the information.
As for the second part, we seem to be on the same page....
September 12, 2014 at 12:00 pm
SimonHolzman (9/12/2014)
September 12, 2014 at 10:12 am
This won't help with performance, but it will save you coding time.
You can change this:
DECLARE @FROMDATE DATETIME = GETDATE()
SET @FROMDATE = DATEADD(HOUR, DATEPART(HOUR, @FROMDATE) * -...
September 12, 2014 at 9:57 am
I would suggest the NOT NULL constraint as Eugene mentioned, but I would also add a DEFAULT to it.
September 12, 2014 at 9:29 am
Christopher Kutsch (9/12/2014)
September 12, 2014 at 8:33 am
gward 98556 (9/12/2014)
WHERE MyNullableCol IS NOT NULL AND MyNullableCol != ''
so there are clearly situations where...
September 12, 2014 at 8:30 am
Maybe something like this:
WITH SampleData AS(
SELECT 1 n UNION ALL
SELECT 2 n UNION ALL
SELECT 3 n UNION ALL
...
September 11, 2014 at 3:02 pm
Viewing 15 posts - 5,821 through 5,835 (of 8,731 total)