Viewing 15 posts - 46,966 through 46,980 (of 59,064 total)
Here's a "fix" for your code... doesn't change a thing in the code... just the way the "seed" for the RAND function works...
select dbo.fx_getrandomnumber(500, 300, rand(CHECKSUM(NEWID())))
FROM dbo.Tally
WHERE N <= 10
That...
November 26, 2008 at 10:09 pm
Ummm... good idea and nice try... but doesn't work to create different random numbers within the same Select. For example, using the eample Select you have with your...
November 26, 2008 at 10:00 pm
November 26, 2008 at 9:29 pm
Either that, or you're mapping doesn't actually equal what's in the file. Could be something stupid like a stray comma in some name in the file.
November 26, 2008 at 9:25 pm
The data conversion is failing because there's bad data in that column somewhere in the file. You need to find out what the bad data/date is and fix it...
November 26, 2008 at 9:24 pm
That would certainly help... but the OP said he can't touch the code because it's generated by and ERP. This is all vry much a moot issue.
November 26, 2008 at 9:21 pm
josephptran2002 (11/26/2008)
SELECT COUNT(ClearedDate) AS 'Month',
...
November 26, 2008 at 9:15 pm
When you get done with your CLR, lemme know...
November 26, 2008 at 9:09 pm
Chris Morris (11/26/2008)
Chris, the link in your signature is broken. You'r missing the right hand bracket on the first instance of the URL IFCode ShortCut.
November 26, 2008 at 9:06 pm
Heh... check out ths clown...
http://www.sqlservercentral.com/Forums/Topic607292-1424-2.aspx#608466
He posted a NUMS function that uses a WHILE loop, has spent most of the post justifying his crud code, and then calls folks "anal"...
November 26, 2008 at 9:33 am
Very nicely done, Ken. Lot's o' work went into that one. Great job.
November 25, 2008 at 11:08 pm
Jeff Moden (11/25/2008)
Server: Msg 137, Level 15, State...
November 25, 2008 at 7:37 pm
Thusi... you don't have these defined in your code anywhere... what are the datatypes and starting or constant values for the following variables?
Server: Msg 137, Level 15, State 2, Line...
November 25, 2008 at 7:24 pm
thusi (11/25/2008)
It actually runs pretty fast!
Heh... "How fast?" 😀 Looks interesting... lemme take a look.
By the way, just to establish the scale of this project... right now you have...
November 25, 2008 at 7:11 pm
It sure does... let's have a race when we're done... CLR vs T-SQL.
November 25, 2008 at 6:59 pm
Viewing 15 posts - 46,966 through 46,980 (of 59,064 total)