Performing Currency Conversion in Power BI

Performing Currency Conversion in Power BI

Table of Contents:

  1. Introduction
  2. Understanding the Data Model
  3. Obtaining Currency Exchange Rate Data
  4. Importing and Preparing the Currency Data
  5. Creating the Measures Table
  6. Calculating the Original Sales Amount
  7. Creating a Filter for the Country
  8. Converting the Sales Amount to the Selected Currency
  9. Displaying the Converted Sales Amount
  10. Conclusion

Introduction

In this video, we will be exploring how to perform currency conversion in Power BI using the currency exchange index. We will start by understanding the data model and the tables involved. Then, we will obtain the currency exchange rate data from a website and import it into Power BI. After preparing the data, we will create a measures table and calculate the original sales amount. We will also create a filter for selecting the country and convert the sales amount to the selected currency. Finally, we will display the converted sales amount in the report. So let's get started!

Understanding the Data Model

Before we dive into the currency conversion process, let's take a moment to understand the data model we will be working with. The data model consists of two tables from the Contoso database: Dim Date and Fact Sales. These tables are linked to each other through a one-to-many relationship. The Dim Date table acts as the dimension table, while the Fact Sales table contains the sales amount column, which is currently in Indian currency (INR).

Obtaining Currency Exchange Rate Data

To perform currency conversion, we will need a third table called the currency table. This table should contain information about different countries, their respective currencies, currency symbols, and the value of the currency in Indian rupees (INR). To get this information, we will use data from the website bookmyforex.com. The website provides tables with exchange rates for various currencies compared to the Indian rupee.

Importing and Preparing the Currency Data

To import the currency data into Power BI, we will use the "Get Data" option and select the web source. We will then paste the URL of the website into the dialog box and proceed with the import. The navigator will display the data queries from the website, and we can select the tables we need. We will transform the data to remove unnecessary columns and ensure the currency values are in a numeric format. Finally, we will append the queries and disable the load for other unnecessary tables.

Creating the Measures Table

Next, we will create a measures table in Power BI. The measures table will contain calculations related to the currency conversion. We will use the modeling tab to create a new table and paste the necessary DAX formulas. The measures table will include measures for the original sales amount and the converted sales amount.

Calculating the Original Sales Amount

The original sales amount measure is a straightforward calculation that sums the sales amount column from the fact sales table. This measure represents the sales amount in Indian rupees (INR) before the currency conversion.

Creating a Filter for the Country

To select the country for currency conversion, we will create a filter using a single-select filter visual. The filter will be linked to the country column in the currency table. When a country is selected, the filter will update the currency symbol and value in Indian rupees displayed in the multi-row card visual.

Converting the Sales Amount to the Selected Currency

To convert the sales amount to the selected currency, we will use the sales amount converted measure. This measure calculates the sales amount by dividing the original sales amount by the value of the currency in Indian rupees (INR) for the selected country. The result is the converted sales amount in the respective currency.

Displaying the Converted Sales Amount

Finally, we will display the converted sales amount in a visual representation. We will compare the original sales amount in INR with the converted sales amount in the selected currency. The visuals will update dynamically when the country filter is changed.

Conclusion

In conclusion, this video demonstrated the process of performing currency conversion in Power BI using the currency exchange index. We learned how to import and prepare currency exchange rate data, create a measures table, calculate the original sales amount, create a country filter, and convert the sales amount to the selected currency. By following these steps, you can analyze sales data in different currencies and gain valuable insights. Thank you for watching!

Highlights:

  • Learn how to perform currency conversion in Power BI
  • Understand the data model and tables involved
  • Import currency exchange rate data from a website
  • Prepare and transform the data for analysis
  • Create a measures table for calculations
  • Calculate the original sales amount in INR
  • Create a country filter for currency selection
  • Convert the sales amount to the selected currency
  • Display the converted sales amount in visuals
  • Gain insights by analyzing sales data in different currencies

FAQ:

Q: Can I convert the sales amount to any currency? A: Yes, you can convert the sales amount to any currency available in the currency table. Simply select the desired country in the country filter, and the sales amount will be converted accordingly.

Q: Can I change the currency exchange rate source? A: Yes, you can modify the source of the currency exchange rate data. Simply update the URL in the data import step to fetch data from a different website providing the required information.

Q: Is the currency conversion dynamic? A: Yes, the currency conversion is dynamic. When you change the country in the filter, the sales amount will be automatically converted to the selected currency in real-time.

Q: Can I use this currency conversion method for other data models? A: Yes, you can apply this currency conversion method to any data model that includes a sales amount column and a currency table. Simply adjust the formulas and mappings accordingly.

I am a shopify merchant, I am opening several shopify stores. I use ppspy to find Shopify stores and track competitor stores. PPSPY really helped me a lot, I also subscribe to PPSPY's service, I hope more people can like PPSPY! — Ecomvy

Join PPSPY to find the shopify store & products

To make it happen in 3 seconds.

Sign Up
App rating
4.9
Shopify Store
2M+
Trusted Customers
1000+
No complicated
No difficulty
Free trial