Viewing 15 posts - 23,971 through 23,985 (of 59,099 total)
K. Brian Kelley (4/3/2014)
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 4:28 pm
mario17 (4/3/2014)
I heard that these days ( after 2008R2) we don't need to CREATE #Temp , you can just do SELECT * INTO #TEMP FROM...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 4:19 pm
K. Brian Kelley (4/2/2014)
There are several good reasons to do this.
1) They prevent against a mistake by someone with privileges who just...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 9:11 am
Siva Ramasamy (4/3/2014)
Thanks for looking into my question. I was not able to understand the usage of connect by statement. Let me try the answer given in the other reply.
I...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 8:37 am
rvenkatesan (4/3/2014)
I am looking for items that have more than one occurrence in track, in the above sample track 204 has 3 distinct Multiples and the track...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 8:32 am
djj (4/3/2014)
Yep I see that now. Again sorry for the misstep.
Nah... not a misstep. I was just making sure. It's good that other people post and you...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 8:30 am
kathy.m.davis.ctr (4/3/2014)
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 8:27 am
HowardW (3/26/2014)
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 8:16 am
djj (4/3/2014)
Try running this:
create table #temp1 (Track INT, Books VARCHAR(10))insert into #temp1 values
(204,'A'),
(204,'B'),
(204,'B'),
(204,'C'),
(206,'A'),
(204,'A'),
(204,'A'),
(203,'A'),
(202,'C'),
(202,'C'),
(202,'B')
SELECT Track, Books FROM #temp1
SELECT DISTINCT Track, Books FROM #temp1
order by 1, 2
Like the OP said, he's not...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 8:01 am
This would do as you ask...
SELECT Track, Books
FROM dbo.YourTable
GROUP BY Track, Books
HAVING COUNT(*) > 1
ORDER BY Track, Books
;
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 7:58 am
A view would be good but this requires dynamic SQL to get the dynamic columns. As you probably know, that won't work in a view.
However, considering how fast the...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 3, 2014 at 7:53 am
Good examples in the article, Greg. I have to take exception to what you listed as "Best Practices", though...
From the article:
--Jeff Moden
Change is inevitable... Change for the better is not.
April 2, 2014 at 11:12 pm
dedicatedtosql (4/2/2014)
I need some guide lines to choose a proper partitioning key for tha tables. LIke below:
What Data type should be choosen?
Can Clurstering Key be diffrent from Partitioning...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 2, 2014 at 10:52 pm
drew.georgopulos (4/2/2014)
Not for nothing, but for me anyway, finding the right stuff here at SCC is really hit or miss.
I agree. It seems like it's always been a problem...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 2, 2014 at 10:38 pm
You might also want to figure out how it got so big. If there's code that makes it that big or you're not doing TLog backups, that could make...
--Jeff Moden
Change is inevitable... Change for the better is not.
April 2, 2014 at 10:31 pm
Viewing 15 posts - 23,971 through 23,985 (of 59,099 total)