Top N - Groupwise

Sep 14, 2007

I am trying to create a query that will show me the top 10 customers for each one of my sales reps. I can get it to give me the top 10 customers for any rep, but I'm not sure how to alter the code to give me top 10 for each rep. Any help would be appreciated.

SELECT TOP 10 T.CUSTOMERS, SUM(T.AMT_0) AS AMT_0
FROM SNXPROD.T_CUSTITM_TTL T
JOIN SNXPROD.BPCUSTOMER C ON C.BPCNUM_0 = T.BPR_0
GROUP BY T.BPR_0
ORDER BY SUM(T.AMT_0) DESC

Thanks!

View 13 Replies


ADVERTISEMENT

Sql Mail On Groupwise

May 9, 2000

Hi,

We are wanting to set up sql mail so that we can email sql server messages to our groupwise email system. We don't use outlook express at all.

Can anyone please help us with this?

Thanks,
Jo

View 2 Replies View Related

Groupwise 5.5 And SQLmail

Feb 1, 2001

Has anyone successfully integrated Groupwise 5.5 with SQLServer 2000? Any suggestions would be appreciated.

Thank you.

View 1 Replies View Related

Sql Mail Alerts & Groupwise

Sep 28, 2001

Can anyone point me in the direction of a good resource
that will help us set up our system so that
notifications from alerts/jobs send emails to our
Groupwise email system?

View 1 Replies View Related

Groupwise Page Numbering And Also Display The Total No. Of Pages In That Particular Group.

Feb 14, 2008



Friends,


I am using SSRS (Sql server reporting services) for one of my report related to EIS-MIS.
i want group wise page numbering and also display the no. of pages for that particular group.

e.g suppose group 1 has 5 pages then it should display
page no. 1 /5, 2/5,3/5,4/5, 5/5. now suppose group change then it shold display 1/4 like this

I have already implemented groupwise page numbering using then custom code and i have call that function from the header portion of the report.
now the question is how can i display the total no. of pages in particular group?

For that i have add one count column in query itself but as we know we can't use field value in header and footer portion and also we can't use global variables in data portion.


So kindly guide me
Thanks,

Manoj Patel

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved