Viewing 15 posts - 2,746 through 2,760 (of 7,636 total)
Paul White (4/30/2009)
I used:
Insert Into dbo.Users (UserName, LastLoggedIn)
SELECT TOP 40000 CHAR(65+FLOOR(RAND(a.column_id*801020 + a.column_id*705020)*12)) + CHAR(65+FLOOR(RAND(a.column_id*6010 + b.object_id)*5)), DATEADD(dd,RAND(a.column_id*600 + b.object_id/1.5)*500,'2008/01/01')
FROM master.sys.columns a CROSS JOIN master.sys.columns b
Dude, what is going on...
April 30, 2009 at 4:14 pm
Also, there is very probably a whole lot of other columns that Steve hasn't mentioned because they are unnecessary, unless you are recreating the whole table.
Still, it's always bothered...
April 30, 2009 at 4:08 pm
john.arnott (4/30/2009)
RBarryYoung (4/30/2009)
... I would have had him two feet off the ground, grasping at his own throat.
...as you sardonically tell him "I find your lack of respect...
April 30, 2009 at 3:54 pm
JohnG (4/30/2009)
...To return a record set from Oracle to ADO.Net you use "REF" cursors. The method that SQL Server uses (firehose output) is not ANSI compliant. ...
Could you...
April 30, 2009 at 3:25 pm
RBarryYoung (4/30/2009)
April 30, 2009 at 3:00 pm
I am pretty sure that this is an Access problem and not a SQL Server one. You might have more luck if you moved this to the Access forum.
Anyway,...
April 30, 2009 at 2:59 pm
By the way, this has nothing to do with Fibonacci series, nor is it related to them (at least not what you have described so far). You are just...
April 30, 2009 at 2:27 pm
Heh. Thanks Lynn and Jeff.
I don't usually post these, but this guy really takes the cake for me.
Knows not to cross-post but at least I only did it once?!?...
April 30, 2009 at 2:10 pm
Adi Cohn (4/30/2009)
April 30, 2009 at 1:57 pm
The other thing to beware of is that there are issues with names whose length hits the max length (40 chars). I didn't see it until I used my...
April 30, 2009 at 1:25 pm
OK, I used to following to generate test data:
delete from Users
Insert into Users
Select TOP 1000000
Left(c1.name, 19)
+ right(cast(newid() as varchar(36)), 2)
+ Left(c2.name, 19)
, Cast( abs(c1.object_id+c2.column_id)/1000.0 as datetime)...
April 30, 2009 at 1:17 pm
GilaMonster (4/30/2009)
RBarryYoung (4/30/2009)
Hmm, depending on the duplicates density, this might be faster:Better on IOs, worse on time (at least on my PC)
Yeah, I'm pretty sure that there's a whole "seek...
April 30, 2009 at 12:16 pm
Hmm, depending on the duplicates density, this might be faster:
;WITH cteUsers as (
SELECT UserID
, UserName
, ROW_NUMBER() OVER (Partition By UserName Order By LastLoggedIn DESC) incr
FROM Users
)
UPDATE cteUsers
...
April 30, 2009 at 11:31 am
Steve Jones - Editor (4/30/2009)
Anyone got a better performing solution than Gail?
Heh. Now you know we'll need to see the execution plan to better answer that. 😀
Seriously though,...
April 30, 2009 at 11:13 am
Viewing 15 posts - 2,746 through 2,760 (of 7,636 total)