title: SSAS MDX Currency conversion based on date of invoice
body: <p>I need to create a calculated measure in the cube which takes a normal LineAmount and calculates the GBP value per invoice. LineAmount is in local currency.</p>
  <p>I tried the following scope.</p>
  <pre><code>SCOPE([Measures].[LineAmountTest],[Cust Invoices].[INVOICEID].MEMBERS); 
          THIS=[Measures].[LINEAMOUNT]*[Measures].[Exchange rate]/100; 
  END SCOPE;
  </code></pre>
  <p>It works if I filter by the Exchange rate date for that InvoiceID as well as the InvoiceID in SSAS.</p>
  <p>However, when I remove the Exchange rate date from the filter, I want the calculation to know that because I selected that InvoiceID, it should know to apply the exchange rate for the invoice date for that InvoiceID only and not the sum of all exchange rates.</p>
  <p>How can I do that?</p>