Viewing 15 posts - 46 through 60 (of 102 total)
thanks,
I made the amendments, in the code you provided you had <= 4 which again returned more then the desired results
so i done this
;with cte_select as
(select
ROW_NUMBER() over (order by count(p.ReviewedBy)...
June 20, 2013 at 5:18 am
I ok i understand,
But doing that will return the first top 4 agents,
I still need to have
My position
person above me
person below me
+ the top performer
?
June 20, 2013 at 5:00 am
hi thanks,
This is the snippet, i think i may have the replaced something incorrectly as now it returns 10 rows.....
;with cte_select as
(select
ROW_NUMBER() over (order by count(p.ReviewedBy) desc) as rownr
,...
June 20, 2013 at 4:29 am
Sorry to be a pain, can you tell me how i can return the top performer as well as the additional three rows?
June 20, 2013 at 4:10 am
Correct, i changed firstname to shortabbr seems to be working 🙂
I cant thank you all enough for helping me on this.
Really was rattling my brain.
Many thanks!
June 20, 2013 at 3:58 am
HanShi (6/20/2013)
HanShi (6/20/2013)You could wrap the above code in another select if you only want a selection of the resultset.
This is the code if you want only the row for...
June 20, 2013 at 3:48 am
Hi Thanks for the snippet,
That returns all individuals + the amount they have checked,
Im going to be passing in the shortabbr from the front end which will then call...
June 20, 2013 at 3:44 am
i tried creating this on SQLFiddle but again this didnt work for some reason,
its a cut down version of the prospectlead table and this table has loads of columns
CREATE...
June 20, 2013 at 3:18 am
GilaMonster (6/20/2013)
June 20, 2013 at 3:06 am
The count is by the Column ReviewedBy which stores the users shortabbr vachar(3) (So i count how many records the users has done by that column by passing in the...
June 20, 2013 at 2:55 am
Hi GilaMontser,
The position would be created depending on how many records the user has checked(ReviewedBy in prospectLead), there is a total of 15 users that check the data on a...
June 20, 2013 at 2:33 am
Thanks for the snippet, and additional information.
June 13, 2013 at 6:58 am
Hi,
Im still confused on why negative numbers are used because from my eyes when u look at
WHEN Ordertype = 3 THEN -2
WHEN Ordertype = 1 THEN -1
if its 3 -2...
June 13, 2013 at 6:49 am
Would you please be able to explain to me what these two lines do
WHEN Ordertype = 3 THEN -2
WHEN Ordertype = 1 THEN -1
Because to me when its 3 that...
June 13, 2013 at 6:36 am
simple as that!!
Thanks so much!!!
June 13, 2013 at 6:34 am
Viewing 15 posts - 46 through 60 (of 102 total)