Viewing 15 posts - 33,586 through 33,600 (of 59,102 total)
Actually, I couldn't wait. I tried using a "Modified Quirky Update" and it beat the tar out of the Calendar Table method for larger start/end date combinations.
I'm still tweekin'...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 8:02 pm
Using the Calendar table I posted in one of the previous posts above, here's what the code at the link that Lutz posted should look like with a couple of...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 5:23 pm
Mark-101232 (6/18/2011)
Mark's second rendition???? Nope not mine, ColdCoffee's offering.
Ack! Sorry. Thanks for the correction, Mark. I'll fix that post. :blush:
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 3:55 pm
LutzM (6/15/2011)
You might want to have a look at the following blog for a better performing alternative:http://sqlblogcasts.com/blogs/sqlandthelike/archive/2009/08/27/sql-and-contiguous-data-ranges.aspx
Hi Lutz,
I strongly recommend that you delete that method from your briefcase. It...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 3:47 pm
Unfortunately, ColdCoffee's code breaks.
CREATE TABLE TEST( SRC varchar(6)not null,
OrgNo varchar(5)not null,
Sdate datetime Not nUll,
Edate datetime Not Null)
INSERT INTO TEST (SRC ,OrgNo ,Sdate ,Edate ) Values ('abc','99999','1/1/1999','12/31/1999')
INSERT INTO TEST (SRC ,OrgNo...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 2:31 pm
@Cold Coffee.
There is a ticking time bomb in it in the form of "Hidden RBAR" because of an "accidental Cross Join". Using the following test data and looking at...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 11:32 am
Mark-101232 (6/15/2011)
WITH Sdates AS (
SELECT a.Sdate,a.SRC,a.OrgNo
FROM TEST a
WHERE NOT EXISTS(SELECT * FROM TEST b
...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 10:50 am
mail2payan (6/17/2011)
1: This T-SQL is not accessible in network, works only in Local Machine, if I tried with local path, I am getting "Access Denied" stored in...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 10:01 am
As a bit of a side bar, using the following as search term in Google. It produces some pretty good hits according to the returned titles...
split CSV in...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 9:57 am
kamala_moorthy (6/17/2011)
...without using PL/SQL...
You might want to try a good Oracle forum or maybe give "Ask Tom" a try. This forum is heavily T-SQL oriented.
I am curious, though. ...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 9:51 am
Just to be sure... pay close attention to what Gail said. There are two inferrals to her answer. To explicity state the not-so-obvious inferral, it [font="Arial Black"]is[/font] possible...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 9:47 am
sqlnaive (6/17/2011)
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 9:35 am
Just a thought. I definitely wouldn't do things this way.
First, because of the 3 digits you allow, you're limiting each department to only 999 tickets. Further, using a...
--Jeff Moden
Change is inevitable... Change for the better is not.
June 18, 2011 at 9:00 am
It's not my job to judge, but nice job, Mark. 🙂
--Jeff Moden
Change is inevitable... Change for the better is not.
June 17, 2011 at 7:31 pm
rajg (6/17/2011)
So I would like to write a single query
Why does it have to be a "single query"?
--Jeff Moden
Change is inevitable... Change for the better is not.
June 17, 2011 at 7:19 pm
Viewing 15 posts - 33,586 through 33,600 (of 59,102 total)