# LM2 - Data Hub SYS13 - Formula Hint 2

Options

Hi Team,

In the Data Hub in module SYS13 Account SKU Filter you setup a Boolean line item to determine whether there is data in DAT03

My formula to be used would of been:  TIMESUM(DAT03) > 0  or TIMESUM(DAT03) <> 0

The 2nd Anaplan formula hint is below:

This is confusing as when/why would you use a Number (1/2) to determine the TRUE/FALSE nature rather than use the native Boolean logic of 0 & 1?

Thanks

Mark

• Options

Hi @MarkTurkenburg

I feel there is a misunderstanding here. What are your concerns? I can see 3 concerns here: (correct me if I'm wrong)

1. There is a 1 / 2 in the THEN ELSE parts of the IF statement?

2. A TRUE FALSE should have been used instead

3. Native Boolean Logic  of 0 &1

Let me start with the number 3. 0 and 1 and are not native Boolean logic. TRUE/FALSE are.

In the 3 parts of an IF THEN ELSE statement, the only part that should resolve to TRUE or FALSE is the part after the IF. However, the THEN and ELSE sections could resolve to ANYTHING -including Boolean.

The Example provided literally translates to .... IF the condition of x not equal 1000 is met THEN resolve to or enter the value of 1, and if the condition is not met enter the value 2.
an IF statement could be used in a line item of any format, in the example provided that format is NUMBER so whatever comes after the THEN and ELSE should resolve to NUMBER.

• Options

Thanks @einas.ibrahim

I think I wrote the post in haste as I was confused as to my formula was not approved as correct in the LM2 but then looking about at the 2nd post the example provided is not actually for the question & hence they were not using 1/2 as the answer

• Options

Hi, and that formula to be used would be TIMESUM('DAT03 Historic Volumes'.Volumes) <> 0

• Options

This is the formula I thought should work but when I try it I get an error saying "Invalid formula for 'SYS13 Account SKU Filter'.Has Data?: Automatic sum of 'DAT03 Historic Volumes'.Volumes over SKU Flat hierarchy is not possible as SKU Flat does not have a built-in top level"

My DAT03 Historic Volumes module uses the SKU Flat list as instructed in the course. How can I solve this error?

• Options

Hello @aaturnbu

Can you please share the instruction to use P3 SKU Flat in the historical volume module? I don't believe using the flat with this module is correct, and that's the reason for the error you are getting.

• Options

Here's the screenshot from the course:

It clearly says to use the flat list.

I found the problem though, I was not using the flat list in SYS13, I had selected the P3 SKU hierarchical list by mistake. It works now that both modules are using the flat list.

• Options

not enough 😞 if then else is missing for boolean format
IF TIMESUM('DAT03 Historic Volumes'.Volumes) <> 0 THEN TRUE ELSE FALSE

• Options

This is what I had, on the exam I got the question wrong.

• Options

yes but you wrote Historic instead of Historical