No_access Posted October 29, 2014 Posted October 29, 2014 I have a report. on this report is a sub summary part,sorted by product group. On this PART is a summary field called totalofmonths it is defined as summary[12] = total of months. It is a repeating field with 12 repeats to show amounts for each month. The months field is a calculation defined as Case( Get( CalculationRepetitionNumber ) = Month(Extend( ShipDate )) ; Extend( ItemPrice by ProductGroup2 ) ) What I need now is to add to that part , the quarterly numbers. so I need to add the repititions from totalofmonths.. I need repitition 1, 2 and 3 only, then 4,5,6 only etc... I can not figure out how to do this. it seems it should be so simple but beyond me at this time.
eos Posted October 29, 2014 Posted October 29, 2014 Create another calc field with 4 repetitions: Case ( Ceiling ( Month ( Extend ( ShipDate ) / 3 ) = Get ( CalculationRepetitionNumber ) ; Extend ( ItemPrice ) ) and summarize that field.
No_access Posted October 29, 2014 Author Posted October 29, 2014 Sometimes I am a moron.. so simple... You are my hero..thanks
comment Posted October 29, 2014 Posted October 29, 2014 Try it this way = Let ( i = Get ( CalculationRepetitionNumber ) - 1 ; Sum ( GetSummary ( totalofmonths [ 3*i + 1 ] ; product group ) ; GetSummary ( totalofmonths [ 3*i + 2 ] ; product group ) ; GetSummary ( totalofmonths [ 3*i + 3 ] ; product group ) ) )The result type is Number and you need 4 repetitions. Create another calc field with 4 repetitions: .. and summarize that field. Ouch. That's a lot of repeated summarizing of the same thing.
No_access Posted October 29, 2014 Author Posted October 29, 2014 this works great, but the new problem becomes past years. Â years are calculated same exact way as above. see attached picture
comment Posted October 29, 2014 Posted October 29, 2014 I am afraid you've lost me. What exactly is this new problem? When you say "years are calculated same exact way as above", I have no idea which way that is.
No_access Posted October 29, 2014 Author Posted October 29, 2014 I have a calculation field called years defined as Case( Get( CalculationRepetitionNumber ) = Right(Year ( Extend(ShipDate ));1) ; Sum(Extend( ItemPrice by ProductGroup2 ) )) it is a repeating field with 8 repeats for years. then I have a a summary field called totalofyears defined as summay[8] = Total of Years in this shows the income for a specific product for that year. as shown in the above image. now for each year I need each quarter broken out. So my thought is to make an another field as mentioned by EOS but use If(Year (Extend( ShipDate ))=Year(Get ( CurrentDate ))-1; Case(Get ( CalculationRepetitionNumber )=Ceiling(Month ( Extend(ShipDate )/3)); Extend(ItemPrice by ProductGroup2));"") to go back 1 year.. however this is not working to get the quarters for 2013... and I would have used Year(Get ( CurrentDate ))-2; to get the data for 2012.. but no good.
eos Posted October 29, 2014 Posted October 29, 2014 Ouch. That's a lot of repeated summarizing of the same thing. I know … First find a way, then find a better one …
comment Posted October 29, 2014 Posted October 29, 2014 now for each year I need each quarter broken out. You can't get an egg back from an omelette. If you want to show 4 quarters for each of the 8 years, you need to summarize by quarter (24 repetitions) first.
Recommended Posts
This topic is 3735 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now