Skip to main content
Solved

Create a Metric off Transaction Table to sum by period but filter by load date

  • October 5, 2024
  • 2 replies
  • 206 views

Forum|alt.badge.img+2

Hello. I have imported a transaction list into Pigment that has two date dimensions. One is “Month” and is = to an accounting period. The second date dimension is the “Load Date” added automatically during the import. Each month, I will append to the data list so at the end, this list could have GL data by period for each load month.

 

I am able to sum the data by period OR by load month but I’m not able to say which load I want to use. My current formula is like this:

'02. Test Pivoted Push'.Amount[BY SUM: '02. Test Pivoted Push'.Department, '02. Test Pivoted Push'.'GL Account', '02. Test Pivoted Push'.Month, '02. Test Pivoted Push'.Subsidiary, '02. Test Pivoted Push'.Vendor]

I want to add in a condition where the results will be based on which load month is selected (something like  ]'02. Test Pivoted Push'.'Load Date'= Set_Last_Opex_Push_Month] where ‘Set_Last_Opex_Push_Month’ will be determined by me. 

Best answer by Lehtohen

Hey Cindy, 
Sounds like you could try using the FILTER-function. 

The formula could look like this:

'02. Test Pivoted Push'.Amount[FILTER: '02. Test Pivoted Push'.’Load Date’ = Set_Last_Opex_Push_Month][BY SUM: '02. Test Pivoted Push'.Department, '02. Test Pivoted Push'.'GL Account', '02. Test Pivoted Push'.Month, '02. Test Pivoted Push'.Subsidiary, '02. Test Pivoted Push'.Vendor]

 

Hope this helps :) 

2 replies

Lehtohen
Master Trendsetter
Forum|alt.badge.img+2
  • Master Trendsetter
  • Answer
  • October 6, 2024

Hey Cindy, 
Sounds like you could try using the FILTER-function. 

The formula could look like this:

'02. Test Pivoted Push'.Amount[FILTER: '02. Test Pivoted Push'.’Load Date’ = Set_Last_Opex_Push_Month][BY SUM: '02. Test Pivoted Push'.Department, '02. Test Pivoted Push'.'GL Account', '02. Test Pivoted Push'.Month, '02. Test Pivoted Push'.Subsidiary, '02. Test Pivoted Push'.Vendor]

 

Hope this helps :) 


Forum|alt.badge.img+2
  • Author
  • Author
  • October 7, 2024

Thanks! it did. I tried filter earlier but likely messed up a syntax. It seems to work now!