cancel
Showing results for 
Search instead for 
Did you mean: 

Help required with IF THEN FORMULA

former_member204618
Active Contributor
0 Kudos

Hi All,

I am trying to get the following formula to work

IF FEE > 0 THEN ROW COUNT

I have tried this:- ((Number of Records > 0) AND (Fee Amount <> 0)) * Number of Records

Also tried

(Fee Amount > 0) * Number of Records

What I am trying to do is count the number of records where there is a fee amount.

But the first one only ever returns all the records and the second one only ever returns 1.

Any help much appreciated.

Thanks

Craig

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

try this If(Fee amount>0,1,0)

or else you can write field routine If source_fields is not initial then result =1

abhishek_rajan3
Contributor
0 Kudos

Hi Craig,

Try this:

KF1 = Count(Fee amount)

KF2 = Sum(KF1)

Use KF2 in the report.

Hope it helps.

Thanks,

Abhishek.

former_member204618
Active Contributor
0 Kudos

Not sure I understand what you are asking here. Can you elaborate please?

former_member204618
Active Contributor
0 Kudos

Abhishek,

There is no SUM function!

Thanks

Craig

former_member209702
Active Participant
0 Kudos

Hi,

Please try combination of following operators in formula:

1. Data Function: Result (this is same as SUM)

2. Data Function: value=1, if operand <>0 else 0 (counter)

this will give you formula as shown below:

SUMCT count(value)

- Geetanjali

former_member204618
Active Contributor
0 Kudos

This still shows me just 1 and I think the problem is down to the aggregation level.

Think my only solution is to derive the count in the transformation when loading the cube or perhaps make it virtual and derive in a BADI.

Thanks anyway

Craig