Viewing 15 posts - 871 through 885 (of 2,171 total)
grevesz (6/9/2008)
If you start a load testing batch process in 10 parallel threads and let it run for an hour and a half, you exhaust your number range...
You have an...
N 56°04'39.16"
E 12°55'05.25"
June 10, 2008 at 12:25 am
Having 4 billion ID's to choose from (-2147483648 to 2147483647), you can insert 10 records per second, every second around the clock, for the next 13.6 years.
N 56°04'39.16"
E 12°55'05.25"
June 9, 2008 at 11:35 am
Will INT not do?
IDENTITY(-2147483648, 1)
will give you 4 billion numbers to choose from.
N 56°04'39.16"
E 12°55'05.25"
June 9, 2008 at 8:47 am
SELECTCASE
WHEN Pos = '19000101' AND Neg = '19000101' THEN 0
WHEN Pos = '19000101' THEN Neg
WHEN Neg = '19000101' THEN Pos
WHEN Pos < Neg THEN Pos
ELSE Neg
END
FROM(
SELECTMAX(CASE WHEN Qty > 0...
N 56°04'39.16"
E 12°55'05.25"
June 9, 2008 at 8:43 am
I just clicked OP's "all post" to see if I didn't invent the wheel again.
If I hadn't, both you and me would present a working solution. What a waste of...
N 56°04'39.16"
E 12°55'05.25"
June 9, 2008 at 7:49 am
ALTER PROCEDURE dbo.uspMyProcedure
(
@Today DATETIME = NULL
)
AS
SET NOCOUNT ON
IF @Today IS NULL
SET@Today = DATEDIFF(DAY, '19000101', GETDATE())
ELSE
SET@Today = DATEDIFF(DAY, '19000101', @Today)
;WITH Yak (ProcessID, theDate, thePath, dc)
AS (
SELECTProcessID,
DATEADD(DAY, DayCount, @Today),
'/' + CAST(ProcessID AS...
N 56°04'39.16"
E 12°55'05.25"
June 9, 2008 at 7:30 am
I see that now.
I responded to a PM and saw that OP posted same question on the forums.
Didn't notice the version.
N 56°04'39.16"
E 12°55'05.25"
June 9, 2008 at 7:08 am
DECLARE@ProcessTest TABLE
(
ProcessID CHAR(3),
ProcessName VARCHAR(50),
FabricType CHAR(1),
ProductType INT,
ProductStyle CHAR(1),
StockType INT,
ProductLine CHAR(1),
DayCount INT,
OverlappedTo CHAR(3),
OverlapDayCount INT,
ProcessAfter CHAR(3)
)
INSERT@ProcessTest
SELECT'001', 'Process1', 'D', 1, 'T', 2, 'W', 12, NULL, NULL, NULL UNION ALL
SELECT'002', 'Process2', 'D', 1,...
N 56°04'39.16"
E 12°55'05.25"
June 9, 2008 at 6:54 am
Did you try my latest suggestion then?
N 56°04'39.16"
E 12°55'05.25"
May 29, 2008 at 12:09 pm
I understand that, BUT WHICH MATCHING preference do you want?
ID = @ID AND pF = @pF AND ClassID = @ClassID
or this
ID = @ID OR pF = @pF OR ClassID =...
N 56°04'39.16"
E 12°55'05.25"
May 29, 2008 at 6:41 am
Which is it?
You can't have both.
N 56°04'39.16"
E 12°55'05.25"
May 29, 2008 at 6:01 am
karthikeyan (5/29/2008)
Peso,You also have used 'OR'.
Yes, because I don't know your business rules.
Please read my previous response carefully and to the very end.
N 56°04'39.16"
E 12°55'05.25"
May 29, 2008 at 5:15 am
Your DELETE #temp1 statements are dangerous.
If a record does not equal to #ID it still might equal #ClassID or sP column.
So you have two diffferents sets of business rules here.
1)...
N 56°04'39.16"
E 12°55'05.25"
May 29, 2008 at 4:22 am
karthikeyan (5/29/2008)
1) Whether my way of approach to split the comma seperated value is correct or not.
2) is there any other way to check the splitted values in...
N 56°04'39.16"
E 12°55'05.25"
May 29, 2008 at 4:05 am
You can with dynamic SQL. but the real question is WHY?
N 56°04'39.16"
E 12°55'05.25"
May 29, 2008 at 4:02 am
Viewing 15 posts - 871 through 885 (of 2,171 total)