Understanding the ISFIRSTOCCURRENCE Constraint and its Effective Solution



Introduction

In this blog post, we will explore the ISFIRSTOCCURRENCE function in Anaplan, a powerful tool used to identify the first occurrence of a value in a list dimension. We'll dive into its applications, a constraint associated with it, and an effective solution to overcome this limitation.

ISFIRSTOCCURRENCE Function:

The ISFIRSTOCCURRENCE function returns a Boolean value of TRUE for the first occurrence of a value in a list dimension. 

For example, you can use ISFIRSTOCCURRENCE to prevent duplicates when creating lists from data.

Formula

ISFIRSTOCCURRENCE(Value, List dimension) Any Format for the "Value" to compare can be used in the above formula.
ExplanationISFIRSTOCCURRENCE is used when we want to have those values which are unique in our module dimensions.
For example, you can see below there are 2 cases presented for a Boolean formatted Line Item 'Valid?'

Case 1:-

Here in this case we have given similar values (i.e. True) in P1 & P1.2, but got True in front of only P1 (in Isfirstoccurance?) that's because of the fact that the True Value is being repeated in P1.2. Similarly, we got True in front of P2 because that's the place where ISFIRSTOCCURRENCE encountered the first False Value in 'Valid?' Line Item for the Policy Number List.

Case 2:-

In this case, we have given the True values in P3 & got True in front of P1 & P3 (in Isfirstoccurance?) that's because ISFIRSTOCCURRENCE encountered with the first False Value in 'Valid?' Line Item at P1 & first True value at P3.

Constraint

There is a big constraint of using ISFIRSTOCCURRENCE function is that, there is an artificial limit is imposed to prevent the searching of large data sets that would slow down the server. This limit is set at 50 million cells. If more than 50 million cells are used with the ISFIRSTOCCURRENCE function, the model rolls back and a notification displays.

Solution

To Resolve the above Problem, we have to create 2 extra Line Items (formatted as of same list dimension on which ISFIRSTOCCURRENCE will gonna apply & summary as First non-blank)
Now after creating these 2 Line Items we just have to apply the below formula ( in Alternate Isfirstoccurance?) & we can see that it is giving us the same result as we get from using the direct formula of ISFIRSTOCCURRENCE.

Time to Rock Your Anaplan Skills! Now you're all set to rock Anaplan like a pro! Use the powerful ISFIRSTOCCURRENCE function and ace your connected planning game. Want to dig deeper? Check out our super-friendly Anaplan course and become a true Anaplan wizard!

Be an Anaplan wizard and take your skills to the next level. If you want to explore further, check out our Anaplan course to unlock the full potential of Anaplan!

OUR COURSES View More