Viewing 15 posts - 11,116 through 11,130 (of 15,381 total)
This should answer all those questions and more. http://www.sqlservercentral.com/blogs/lynnpettis/2009/03/25/some-common-date-routines/%5B/url%5D
August 2, 2012 at 9:38 am
As Lynn said you didn't provide much to go on but an extremely vague shadow of an idea. I think that the gist of your question is "How can I...
August 2, 2012 at 9:37 am
You posted a bunch of stuff in your first post that somewhat looks like it came from your table. Turn that into something we can use and we can help.
Turn...
August 2, 2012 at 8:39 am
vishnurajeshsat (8/2/2012)
Thanks for your reply.I cant able to show my table in this forum. Can you tell me how to add image...
August 2, 2012 at 8:36 am
drew.allen (8/2/2012)
WITH ActiveUpdates AS (
SELECT [ID], SortOrder, isActive, ROW_NUMBER() OVER( ORDER BY SortOrder DESC, [ID] ) - 1 AS rn
FROM @CustomerConditions
)
UPDATE...
August 2, 2012 at 7:49 am
This should work with your sample data.
select *
from CustomerConditions
where IsActive = 1
order by SortOrder
begin transaction
update CustomerConditions
set SortOrder = x.RowNum
from CustomerConditions c
cross apply
(
select ConditionID, ROW_NUMBER() over (order by isnull(SortOrder, 9999999), ConditionID)...
August 1, 2012 at 3:25 pm
Lynn Pettis (8/1/2012)
August 1, 2012 at 3:08 pm
But the point was still that functionally "BETWEEN" in TSQL doesn't match what one would logically expect from the name. Which would be, "is value in the range defined by...
August 1, 2012 at 3:04 pm
I think I understand what you are trying to do. Can you post some ddl (create table) and sample data (insert statements) in a consumable format?
August 1, 2012 at 2:29 pm
I understand your point but the lowest value first makes sense. Would you tell somebody that you will come visit them sometime BETWEEN 7pm and 6pm? They would look at...
August 1, 2012 at 2:07 pm
morepainot (8/1/2012)
Sean Lange (8/1/2012)
morepainot (8/1/2012)
August 1, 2012 at 1:00 pm
morepainot (8/1/2012)
August 1, 2012 at 12:37 pm
•Do all staged tables exist in the source and in the stage database?
•Do all staged columns exist in the source and in the stage database?
•Is the data type of all...
August 1, 2012 at 12:33 pm
Oh thats only there cause I have to create a table there. Im not sure what columns to add to it so I left it blank for the time being....
August 1, 2012 at 12:25 pm
Okay, understood. This code is really long but Im going to post it with all the errors, mostly fixed. This included the procs usp_PreStageValidation and usp_PostStageValidation
You need step away from...
August 1, 2012 at 10:38 am
Viewing 15 posts - 11,116 through 11,130 (of 15,381 total)