dbTalk Databases Forums  

Currency Exchange Rates

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Currency Exchange Rates in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jim Linder
 
Posts: n/a

Default Currency Exchange Rates - 05-18-2004 , 07:46 PM






I am trying to get a currency exchange rate calculation functioning in AS2K. The main cube has an Amount measure and a shared Time dimension (as well as others). The currency cube has a ExchangeRate measure with the shared Time dimension and a private Country dimension

I have created a virtual cube from these two cubes and a calculated measure called LocalAmount using the following MD

ValidMeasure([Measures].[Amount])*ValidMeasure([Measures].[ExchangeRate]

When I select a country, the LocalAmount gets calculated, but it is not correct. For example
Amount = 83,574,061.8
ExchangeRate= .8
LocalAmount= 69,610,507.57 It should be 69,366,471.3

Is there something I should be doing different

If you would point me at a detailed example on how to do this right, it would be greatly appreciated

Thanks
Ji


Reply With Quote
  #2  
Old   
Yuan Shao
 
Posts: n/a

Default RE: Currency Exchange Rates - 05-19-2004 , 09:23 AM






Hi Jim,

According to your description, I learned the value you got from the
calculated measure is incorrect. If I have misunderstand, please feel free
to let me know.

Based on my research, it seems when the ExchangeRate is 0.833, the value of
the LocalAmount will be 69,610,507.57. I would like you to check the data
type and check if the value of ExchangeRate has been truncated. If
everything is fine, but the problem still persists, I would like you to
provide a sample on FoodMart 2000 database showing this problem so that I
can perform further research.

Thank you,

Michael Shao
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.


Reply With Quote
  #3  
Old   
Jim Linder
 
Posts: n/a

Default RE: Currency Exchange Rates - 05-19-2004 , 11:01 AM



The Analysis Manager cube browser showed the ExchangeRate value to be .83, but the source table had it at .8329 so the calculated LocalAmount was really correct. Sorry for the mistake, but I did a lot of trial and error attempts at this because I could not find a complete example to learn from. I thought it was just another coding error on my part

Is there a good example on doing currency exchange rates in Analysis Server somewhere

Thanks
Ji



Reply With Quote
  #4  
Old   
Yuan Shao
 
Posts: n/a

Default RE: Currency Exchange Rates - 05-20-2004 , 08:36 AM



Hi Jim,

Thanks for your information. I would like you to know the display format
and data type of this problematic measure. It is mostly suspected the
display format is stardart but the data type is double. In this way, the
data of the measure will be truncated using cube browser.

In this case, please change the display format to percent and check to see
if it is able to fix this problem.

Thank you,

Michael Shao
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights


Reply With Quote
  #5  
Old   
Jim Linder
 
Posts: n/a

Default RE: Currency Exchange Rates - 05-20-2004 , 10:16 AM



Hi

I should have been clearer in my last response. When I saw the source table amount was getting rounded down from .8329 to .83, I changed the format from Standard to Percent. That corrected the error with the displayed ExchangeRate amount in Analysis Manager

What I have so far seems to be working OK, but if there is a more robust process already documented, I would like to take advantage of that

Is there a white paper or a good example on doing currency exchange rates in Analysis Server somewhere?

Thanks
Jim

Reply With Quote
  #6  
Old   
Yuan Shao
 
Posts: n/a

Default RE: Currency Exchange Rates - 05-21-2004 , 12:42 PM



Hi Jim,

Based on my search, I am afraid there is not a built-in sample/white paper
specified for currency exchange rates in analysis server. However, if you
encounter any problem when you do currency exchange rates in Analysis
Server, please do not hesitate to post in the newsgroup. I am happy to be
of assistance.

Michael Shao
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.