|
Prev: Two Datasets, one matrix
Next: RS 2005 and MOSS 2007
From: Zack G on 12 Jun 2008 16:36 I have a report that groups transactions on the customer level and then the customers according to some dollar value associated with each customer. I would like to include a ranking for each customer based on that dollar value, i.e. the highest dollar value customer will be 1 and so on. I was thinking it might be possible to create a variable that starts at one and adds one every time the group breaks and print that variable as the ranking. Is this possible and if not, is there another way to approach the problem? Thanks.
From: Wayne on 16 Jun 2008 13:48 Have you looked into using the row_number() and over/partiton clauses of the select command? "Zack G" wrote: > I have a report that groups transactions on the customer level and > then the customers according to some dollar value associated with each > customer. I would like to include a ranking for each customer based on > that dollar value, i.e. the highest dollar value customer will be 1 > and so on. I was thinking it might be possible to create a variable > that starts at one and adds one every time the group breaks and print > that variable as the ranking. Is this possible and if not, is there > another way to approach the problem? Thanks. >
From: Zack G on 19 Jun 2008 16:16 I have a stored procedure and I have to use the data that it is returning so I cannot modify the SELECT statement (I hope I am understanding you correctly). On Jun 16, 1:48 pm, Wayne <Wa...(a)discussions.microsoft.com> wrote: > Have you looked into using the row_number() and over/partiton clauses of the > select command? > > "Zack G" wrote: > > I have a report that groups transactions on the customer level and > > then the customers according to some dollar value associated with each > > customer. I would like to include a ranking for each customer based on > > that dollar value, i.e. the highest dollar value customer will be 1 > > and so on. I was thinking it might be possible to create a variable > > that starts at one and adds one every time the group breaks and print > > that variable as the ranking. Is this possible and if not, is there > > another way to approach the problem? Thanks.
From: Zack G on 19 Jun 2008 16:16 I was hoping this could be done entirely within SRS. On Jun 16, 1:48 pm, Wayne <Wa...(a)discussions.microsoft.com> wrote: > Have you looked into using the row_number() and over/partiton clauses of the > select command? > > "Zack G" wrote: > > I have a report that groups transactions on the customer level and > > then the customers according to some dollar value associated with each > > customer. I would like to include a ranking for each customer based on > > that dollar value, i.e. the highest dollar value customer will be 1 > > and so on. I was thinking it might be possible to create a variable > > that starts at one and adds one every time the group breaks and print > > that variable as the ranking. Is this possible and if not, is there > > another way to approach the problem? Thanks.
|
Pages: 1 Prev: Two Datasets, one matrix Next: RS 2005 and MOSS 2007 |