Viewing 15 posts - 54,526 through 54,540 (of 59,072 total)
Ok... just ran Matt's code against the million row table... Ladies and Gentlemen, we have a tie! :w00t: Matt's function took the same amount of time as mine.
One thing...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 11:34 pm
First, nicely done, Matt! Yeah, if you don't include the start date as a Week Day, then you're correct... adding 30 Weekdays to '20070514' would, in fact, be 6/25...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 11:31 pm
Heh... now you've made a real mess of the formatting... :hehe:
Ooops... never mind... dunno what happened but it went back to a good format when I posted this message...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 10:47 pm
Matt Miller (10/18/2007)
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 9:31 pm
Ah... sorry, it doesn't work as expected... it includes weekends which is what Greg is trying to exclude... in terms of your example, he wants to add 30 "week days"...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 9:16 pm
How many times Government changed calendar in last 20 years?
Heh... here in the States, ya just don't know... look what they've done to DST, Primary days, and the...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 9:01 pm
Matt Miller (10/18/2007)
I don't have a HUGE database on hand with relevant data, but on 50K records...maybe a second.
Thanks, Matt. Like I've said so many times, I don't have...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 8:55 pm
Now we try to elevate ourselves to Jeffs' level
Heh... nah... it's not worth all the nosebleeds due to lack of Oxygen 😀
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 8:48 pm
joe joe (10/17/2007)
Hi Jeff,I looked into the ZP4, and truely looks very handy. But I don't have any adresses in USA, only in Europe.
But thanks for the tip 🙂
Ack... my...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 8:47 pm
Luis,
How many rows do you end up with in your result set?
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 8:15 pm
Now, that looks like a good use for a CLR... how's the performance? (I can't test it... don't have 2k5 available)...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 7:57 pm
Sounds like a pretty good plan... GUI is the place where such formatting should occur.
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 7:52 pm
sp_HelpFile
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 6:24 pm
Matt... haven't tested it, but I agree... I think you've probably done it and it looks like the performance will outstripe any table solutions in this case... gonna have to...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 5:48 pm
mrpolecat (10/18/2007)
declare @startdate datetime, @days int
set @startdate = '1/1/2007'
set...
--Jeff Moden
Change is inevitable... Change for the better is not.
October 18, 2007 at 5:44 pm
Viewing 15 posts - 54,526 through 54,540 (of 59,072 total)