Skip to main content

I have an integer dimension by month, vendor, and function that has “1” if that vendor was employed in that specific month. How can I cumulate but reset if the employment is blank? I.e. some vendors are employed for 3 cumulative months, then take a 7 month break, and come back for 2 months so I would want the respective values to show 3 cumulated and then 2 cumulated. Thank you!

Hi ​@ljanowski,

 

Instead of CUMULATE() you can utilize the PREVIOUS() function.

Combined with an IF statement you can check for blank cells, and reset the cumulated value.

 

IF ( ISDEFINED ('Vendor Employed') ,PREVIOUS(Month)+'Vendor Employed', BLANK)

The first line in the below table is simulating your input metric.