Interview Questions   Tutorials   Discussions   Programs   Videos

# OBIEE - I have a subject area table containing records with columns account no., txn code and amount e.g. A/C No. Txn Code Amount A01000 T1000 \$5000.00 A01000 T2000 \$3000.00 A01100 T1000 \$8888.00 A01100 T2000 \$4444.00 I want to get a result of Net amount by A/C No. e.g. Net Amount for account A01000 = \$5000 (T1000) - \$3000 (T2000) = \$2000 How can I do this in an analysis?

448
views
asked DavidLee November 3, 2013 06:23 AM

I have a subject area table containing records with columns account no., txn code and amount e.g. A/C No. Txn Code Amount A01000 T1000 \$5000.00 A01000 T2000 \$3000.00 A01100 T1000 \$8888.00 A01100 T2000 \$4444.00 I want to get a result of Net amount by A/C No. e.g. Net Amount for account A01000 = \$5000 (T1000) - \$3000 (T2000) = \$2000 How can I do this in an analysis?

If T2000 value  > than T1000 value, ?
flag

answered By pavan kumar   0
create a  new logical column amount1 ..write a case statement like if TxnCode =T1000 then Amount1=Amount*1
ifTxncode =T2000 then Amount1= Amount*-1

For the new measure Amount1 give aggreagation as Sum

then drag Account No and Amount1 to analytics. We can get desired result
flag

### Join with account you already have

Preview

Online-Classroom Classes
www.writeabc.com

1 person following this question

Question tags

obiee × 1

Asked 3 years and 4 months ago ago
Number of Views -448
Number of Answers -2
Last updated
2 years and 11 months ago ago

Ready to start your tutorial with us? That's great! Send us an email and we will get back to you as soon as possible!