You need to sign in to do that
Don't have an account?
Philip Brining
PrevGroupVal & ParentGroupVal
I've got a report I am trying to write and I need to use one or other of Prev/Parent Group Val custom formlae I think. I've read the SFDC help and resources on this forum but still can't get my head around what I need to do to get this to work.
I have a matrix report Accounts with Orders and Products. Orders is a cusom object called Order.
Account has a custom field called Region__c which is a pick list and represents the region that an account is in.
Order has a custom field called X9L_Equiv__c which reprents the 9 litre equivalent of an order. We're talking alcohol here - the 9L= of a 12 x 750ml case of Gin is 1: the 9L= of a 6 x 500ml case of Cherry Vodka is 0.33. An order containing 6 cases of Cherry Vodka would have a Count of 1, Quantity of 6, 9L= of 2. Hopefully I've clarified not complicated!
My matrix report is like this:
MONTH 1 MONTH 2 Grand Total
Region Gin Cherry Vodka Total Gin Cherry Vodka Total GT
London 2 5 7 6 4 10 17
South 3 3 2 5 7 10
North 8 1 9 3 3 12
GRAND TT 10 9 19 11 9 20 39
What I'd like is
MONTH 1 MONTH 2 Grand Total
Region Gin Cherry Vodka Total Gin Cherry Vodka Total GT
London 5% 13% 18% 15% 10% 26% 44%
South 8% 8% 5% 13% 18% 26%
North 21% 3% 23% 8% 8% 31%
GRAND TT 26% 23% 49% 21% 31% 51% 100%
I cannot figure out the syntax of the two formulas in respect of referencing fields that I want to group by.
PARENTGROUPVAL(Order__c.X9L_Equivalent_of_Order__c:SUM, ACCOUNT.REGION__c, PRODUCT.NAME) gives me a field does not exist error on ACCOUNT.REGION__c
Hope this makes sense and someone can help me.
Thanks
I have a matrix report Accounts with Orders and Products. Orders is a cusom object called Order.
Account has a custom field called Region__c which is a pick list and represents the region that an account is in.
Order has a custom field called X9L_Equiv__c which reprents the 9 litre equivalent of an order. We're talking alcohol here - the 9L= of a 12 x 750ml case of Gin is 1: the 9L= of a 6 x 500ml case of Cherry Vodka is 0.33. An order containing 6 cases of Cherry Vodka would have a Count of 1, Quantity of 6, 9L= of 2. Hopefully I've clarified not complicated!
My matrix report is like this:
MONTH 1 MONTH 2 Grand Total
Region Gin Cherry Vodka Total Gin Cherry Vodka Total GT
London 2 5 7 6 4 10 17
South 3 3 2 5 7 10
North 8 1 9 3 3 12
GRAND TT 10 9 19 11 9 20 39
What I'd like is
MONTH 1 MONTH 2 Grand Total
Region Gin Cherry Vodka Total Gin Cherry Vodka Total GT
London 5% 13% 18% 15% 10% 26% 44%
South 8% 8% 5% 13% 18% 26%
North 21% 3% 23% 8% 8% 31%
GRAND TT 26% 23% 49% 21% 31% 51% 100%
I cannot figure out the syntax of the two formulas in respect of referencing fields that I want to group by.
PARENTGROUPVAL(Order__c.X9L_Equivalent_of_Order__c:SUM, ACCOUNT.REGION__c, PRODUCT.NAME) gives me a field does not exist error on ACCOUNT.REGION__c
Hope this makes sense and someone can help me.
Thanks
PARENTGROUPVAL(summary_field, parent_row_grouping, parent_column_grouping)
Can you do a screenshot of your report?
For instance, here is a formula I used to calculate how much percentage of sales each month. I'm taking the sum of cases ordered and dividing by the total from the summary fields.
Order_Item__c.Cases_Ordered__c:SUM/PARENTGROUPVAL(Order_Item__c.Cases_Ordered__c:SUM, ROW_GRAND_SUMMARY, COLUMN_GRAND_SUMMARY)
So the only fields you can work with are those that are summarised or numerical - I was trying to reference Region (Picklist). I'm still not sure what to do to get what I want.
Thanks
Phil
Thanks
Phil
Let me know if that works for you!
The report now looks like this:
I have verfied that the results are correct - 97% of Berkeley Square Gin orders were in London in September 2013, adn the remaining 3% were in Scotland.
Many thanks
Phil
Also, not sure how to remove "#Error". I think if you filter on orders that only have values that might do it.
And thanks for sharing the challenge, forced me to dig deeper into some areas I haven't looked that hard at!
Thanks
Phil
The #Error is the result of a Divide by Zero error in your formula, basically you're "breaking The Laws of Math" to remove the #Error, you'll need to amened your Formula with an "exit" that basically says IF(Value = 0, 0, else continue on with the rest of the formula...
Of all the things to do in the world, literally ALL of the the options available
(here's just a few)
Help an eldery person
Teach a child to read
Donate to a food pantry
Plant a tree
Instead, you chose to be a Spammer
Your parents must be so ashamed of you