Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I currently have a code written that identifies customers on the basis of their credit rating and what month they became a client. The chart box then regurtitates the number of customers for each of our five categories on a monthly basis. However, now I need it do the same but take the number in each category and divide it by the total number of customers in that month. What I like to be able to do is simply have each number divide by the expression total I have added as the bottom row. Any ideas?
The code I just tried looks like this, but gives me a result of 0:
count({1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} Acct_Pre_Screen_Black)/count(TOTAL<{1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} Acct_Pre_Screen_Black> {1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} Acct_Pre_Screen_Black)
Have you tried this?
=count({1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} Acct_Pre_Screen_Black)
/count({1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} TOTAL Acct_Pre_Screen_Black)
Hi,
I believe you shouldn't put the set expression within the TOTAL<fields>, so maybe change it to
=count({1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} Acct_Pre_Screen_Black)
/count({1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} TOTAL<Acct_Pre_Screen_Black> Acct_Pre_Screen_Black)
What are your dimensions in your chart? I assume the first part of your division calculates successfully to a number?
Regards,
Stefan
I say what you are saying, but that results in all 1's. Basically that makes it so each of the five categories divideds by the total of itself, I need it to divide by the sum of all. And yes, if I eliminate the division, I get a number. That is how this report began but now we are more interested in the numbers as a % of the total.
Have you tried this?
=count({1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} Acct_Pre_Screen_Black)
/count({1<Acct_CCDMonth = {1}, Acct_CCDYear = {$(vThisYear)}>} TOTAL Acct_Pre_Screen_Black)
Thanks, funny how the simplest measure is so often the solution. I didn't realize you could utilize total without a <field> expression.