Viewing 15 posts - 3,976 through 3,990 (of 5,504 total)
The easiest way would be to change your columns from varchar into datetime format. You could add another column each with datetime format and copy the varchar values into the...
March 16, 2010 at 12:57 pm
Paul White (3/16/2010)
Yikes. XML is not the right tool for the job when it comes to string splitting.
The tally-table method presented by Lutz, Bob, and Jeff is far,...
March 16, 2010 at 12:18 pm
Something like this?
DECLARE @OutlineNumber VARCHAR(1000)
SET @OutlineNumber= '.I.A.1.b.'
SELECT STUFF(SUBSTRING(@OutlineNumber,1,CHARINDEX('.',@OutlineNumber,N+1)),1,1,'')
FROM dbo.Tally
WHERE N < LEN(@OutlineNumber)
AND SUBSTRING(@OutlineNumber,N,1) = '.'
The variable needs to have a dot...
March 15, 2010 at 5:42 pm
No need for further discussion.
Seems like the question has already been answered here .
Side note: since the solution in the other thread is based on ROW_NUMBER I guess the...
March 15, 2010 at 3:59 pm
redrabbit9999 (3/15/2010)
Do you know how to pivot transform the data so that it looks like this:
Unpivoted Data:
Column1 Column2 Column3
A ...
March 15, 2010 at 3:57 pm
Glad I could help 😀
And sorry for underestimating the performance improvement 😉
March 15, 2010 at 11:11 am
Hi
thanks for your informations but ALL TIMES I GET
Msg 170, Level 15, State 1, Line 7
Line 7: Incorrect syntax near 'PIVOT'.
Message Dou you have any suggestion for me
Duplicate post.
Please...
March 14, 2010 at 5:55 pm
muratistanbul (3/14/2010)
Msg 170, Level 15, State 1, Line 7
Line 7: Incorrect syntax near 'PIVOT'.
Message is anybody have suggestion for...
March 14, 2010 at 5:53 pm
RBarryYoung (3/14/2010)
March 14, 2010 at 4:59 pm
I'd expect the problem is within the setting of your DATEFORMAT parameter.
But the major problem is: you're trying to treat a date value as a string.
If it's a date, use...
March 14, 2010 at 4:11 am
Ok, here's what I came up with. I'm not sure if it'll help but it might be at least something to start with.
CREATE TABLE #temp
(id INT IDENTITY(1,1),
col VARCHAR(60) ...
March 13, 2010 at 5:33 pm
To any of you folks from "down under":
Congrats for winning the Hockey World Championship in India!
We didn't have that much of a chance in the final though...
March 13, 2010 at 11:54 am
@paul-2: CONGRATULATION to be one of the top 25!
March 13, 2010 at 11:32 am
The reason for the bad performance is you're 'climbing up' one level each time you select one of the values from the Circuit node. Try to use CROSS APPLY instead.
I'd...
March 13, 2010 at 10:31 am
scott.atkins (3/13/2010)
Im just curious how would you write a CURSOR script though? Would some one be able to...
March 13, 2010 at 9:55 am
Viewing 15 posts - 3,976 through 3,990 (of 5,504 total)