Viewing 15 posts - 16 through 30 (of 55 total)
TravisDBA (1/17/2012)
Please, don't go out and cut the hands off of someone because they were stealing bread when they are homeless. Its the basic principles we are after, and this...
January 17, 2012 at 11:50 am
TravisDBA (1/17/2012)
butler-628023 (1/16/2012)
January 17, 2012 at 9:57 am
butler-628023 (1/16/2012)
January 17, 2012 at 9:07 am
FROM PERSONAL EXPERIENCES:
As a Jr SQL dev, I've have always tried to abide by one rule: there is a median between Work and Home, and I will always stay in...
January 17, 2012 at 9:05 am
L' Eomot Inversé (1/13/2012)
stephen99999 (1/13/2012)
January 13, 2012 at 12:03 pm
I think the best way to do this is to just test on various sample data. Really change it up, and see if you can "break" the code. If not,...
January 13, 2012 at 6:52 am
I see your point now. In all actuality, your prior code:
select count(distinct datakey) as Unique_Dataset
from (select *, row_number() over(partition by datakey order by case when Datakey!='' then 0 else 1...
January 12, 2012 at 10:36 am
Mark-101232 (1/12/2012)
bicky1980 (1/12/2012)
stephen99999 (1/12/2012)
January 12, 2012 at 7:58 am
in table format, bicky, please post what you are expecting your results to look like. Earlier you stated you wanted to see 9, 6, etc to be returned, and now...
January 12, 2012 at 6:25 am
@bicky
It has to be one of these two options lol. For each option, I started out with a quote on your desired results should be, as well as some...
January 11, 2012 at 6:52 pm
Alright, lets try this
declare @t table(indkey nvarchar(2),datakey nvarchar(4),landline nvarchar(11),mobile nvarchar(11),email nvarchar(20))
insert into @t values ('1','0001','01234567890','0712345679','1@test.co.uk')
insert into @t values('2','0001','01234567890','','1@test.co.uk')
insert into @t values('3','0002','01234567891','','2@test.co.uk')
insert into @t values('4','0002','01234567890','','2@test.co.uk')
insert into @t values('5','0002','','07123456789','')
insert into @t...
January 11, 2012 at 2:35 pm
bicky1980 (1/11/2012)
stephen99999 (1/11/2012)
SELECT datakey,COUNT(datakey) OVER(Partition by datakey) AS Uniquedatakey,
...
January 11, 2012 at 2:05 pm
worker bee (1/11/2012)
January 11, 2012 at 1:59 pm
Wouldnt a date table work in this situation as well? sort of like what we find in data warehouses?
January 11, 2012 at 1:08 pm
jbalbo (1/11/2012)
thanks that works great...hate to be a pain I really am new, can u explain why that is, just so I know?
Thanks
lol I am no expert either, any...
January 11, 2012 at 12:23 pm
Viewing 15 posts - 16 through 30 (of 55 total)