6 Replies Latest reply: Jul 11, 2011 11:24 AM by Kalyan Nadella RSS

    Creating a calculation in Script from 2 different Tabs

    Kalyan Nadella

      Hi,

       

      I need to create a calculated field in script from 2 different tabs in Edit Script of Qlikview document. In Tab1(let's call it 'Conversion Rate' Tab) we have Conversion Rates column and Tab2 (Lets call it 'Transactions' tab) which has all the transactions. Now i need to add a calculated column in 'Transactions' tab that calculates Base Amount (ActualAmount * ConversionRate)  where ActualAmount is from 'Transactions' Tab while ConversionRate in 'Conversion Rate' tab. Any Ideas how can I acheive this?

        • Creating a calculation in Script from 2 different Tabs
          Nagaian Krishnamoorthy

          If the Transactions table and [Conversion Rate] table are linked by the currency code field, you can calculate the Base Amount in the charts, using the expression given by you.

           

          If you want to do the calculation in the load script, you may have to bring the ConversionRate to the Transactions table using a left join or mapping load of ConversionRate and then calculate the Base Amount in the script.

           

          Hope this helps.