Skip to Main Content

Analytics Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Need help to calculate the column formula:

User_B7ZTHMay 7 2019 — edited May 31 2019

Hello Experts,

I am working on a column formula which is mentioned below :

CASE

WHEN

"Fact-Shanpshots"."DOC_TYPE" NOT IN ('AK', 'AL', 'MD', 'ZA') AND 

"Fact-Shanpshots"."DOC_TYPE" NOT LIKE 'Z%' and

"Dim - Time - Balance Date"."DAY_ID" AND

"Fact-Shanpshots"."BALANCE_INDICATOR" <> 'p'

THEN

"Fact-Shanpshots"."AMOUNT"

else 0

end

I have to use the aggregation SUM and Distinct but don't know how to use this logic in rpd:

something like:

SUM(DISTINCT(CASE

WHEN

"Fact-Shanpshots"."DOC_TYPE" NOT IN ('AK', 'AL', 'MD', 'ZA') AND 

"Fact-Shanpshots"."DOC_TYPE" NOT LIKE 'Z%' and

"Dim - Time - Balance Date"."DAY_ID" AND

"Fact-Shanpshots"."BALANCE_INDICATOR" <> 'p'

THEN

"Fact-Shanpshots"."AMOUNT"

else 0

end ))

Any idea will be welcome.

Thanks & Regards,

Abhi

Comments