Writing a rule for string element

Post Reply
anote
Posts: 13
Joined: Fri Jun 13, 2008 5:35 pm

Writing a rule for string element

Post by anote »

I don’t know which function I have to use, but below is the example.

Cube: A
Amount Currency Explanation(String)
33000 THB AAA
1000 USD (It should show “AAA”, but it doesn’t)

Once I change the currency from “THB” to “USD”. The amount convert from 33000 to 1000 automatically from the exchange rate by using TM1 rule. However, explanation “AAA” doesn’t show. I don’t know the rule to get data. Could anyone please suggest me?
User avatar
Steve Rowe
Site Admin
Posts: 2410
Joined: Wed May 14, 2008 4:25 pm
OLAP Product: TM1
Version: TM1 v6,v7,v8,v9,v10,v11+PAW
Excel Version: Nearly all of them

Re: Writing a rule for string element

Post by Steve Rowe »

Hi anote,
I'm not sure that you have posted enough information for us to establish what you are trying to make happen. If you could perhaps list the the dimensions in your cube and paste your rules into the post then we might be able to help you.

Cheers,
Steve
Technical Director
www.infocat.co.uk
Lukas Meyer
Posts: 51
Joined: Thu Jul 24, 2008 6:14 am

Re: Writing a rule for string element

Post by Lukas Meyer »

I assume you have something like

Code: Select all

['USD', 'Amount'] = DB('cube','THB','Amount') * 0.03;
Maybe you look up the numeric value (you should do so ;) ) or you have more elements.

Try this:

Code: Select all

['USD', 'Amount'] = DB('cube','THB','Amount') * 0.03;
['USD', 'Explanation'] = S: DB('cube','THB','Explanation');
notice the S: - this one does the trick.

Did I guess correctly?
anote
Posts: 13
Joined: Fri Jun 13, 2008 5:35 pm

Re: Writing a rule for string element

Post by anote »

Thank you very much for your kindly help.
It works :D
Post Reply