Viewing 15 posts - 16 through 30 (of 30 total)
I done this comparisson (see my posts before) . The result is practically the same. Again, there is no magic Internally set based solution...
June 5, 2007 at 8:31 pm
Just for fun:
WHILE LOOP TEST...
100000000 The final count (just to show work was done)
111480 Duration in milliseconds
------------------------------------------------------------------------------
SET BASED TEST...
100000000 The final count (just to show work was done)
15296 Duration...
June 5, 2007 at 8:02 pm
First time
WHILE LOOP TEST...
1000000 The final count (just to show work was done)
1073 Duration in milliseconds
------------------------------------------------------------------------------
SET BASED TEST...
1000000 The final count (just to show work was done)
263 Duration in milliseconds
------------------------------------------------------------------------------
Next...
June 5, 2007 at 7:52 pm
Jeff, I have 2.18 Ghz Intel Duo, 4GB RAM, single HD , 2005 Developer Edition SP2, laptop.
I believe, for this example any solution should work practically the same, loop or...
June 5, 2007 at 7:09 pm
I have been three times in position of database architect responsible for design, implementation and support of multiple databases simultaneously.
The database independent approach never worked, because:
· Some...
May 31, 2007 at 11:42 pm
BTW, Jeff, your solution first time - 32 sec, then in average 13 sec
May 31, 2007 at 8:19 pm
BIZZ
BUZZ
Elapsed Time: 19393 ms
I just ran it
2 times less efficient that optimizied loop approach that use CASE
Still good enough
May 31, 2007 at 8:13 pm
You are right
a) I got under impression that you meant that it is a bug in SQL Server
b) by "scalability" I meant that your code is not scalable for...
May 31, 2007 at 11:02 am
2.b "I see your point now. It is a bug, not a scalability issue. Your example with the scientific notation made it more clear."
It's not a bug. The problem is...
May 31, 2007 at 10:33 am
Hi webrunner,
2.b Even in your example you should be surprized, why charindex returns 2, and not
select CHARINDEX('.',1300001.0
May 31, 2007 at 8:55 am
Sergiy, Single HDD but 7200 rpm. And I've used INTO #tempTable for set-based solution. Sure, I didn't. But, anyway, the point is that for some hardware configuration in-memory loop-based solution...
May 30, 2007 at 11:57 pm
It runs 9 sec on mine. I have Intel Dual Core 2.16 Ghz but 4GB of RAM. Interesting enough, the fastest set based solution runs 15 sec.
May 30, 2007 at 11:05 pm
1. "I did it without % because I couldn't find the mod function by name in Books Online" - because % is an operator, not a function
2. "IF (CHARINDEX('.',@DivResultBy3) =...
May 30, 2007 at 3:10 pm
Let's assume that we have the numbers populated in some table #numbers (the same solution will work with CTE)
As far as I tested, the following solution about 2 times faster...
May 29, 2007 at 1:03 am
It's funny
One day our department received a piece of paper from the vice president who said these were the specifications for a new...
April 30, 2007 at 12:25 am
Viewing 15 posts - 16 through 30 (of 30 total)