Reporting Rates
Provides a reporting-ready view of exchange rates with normalized currency pairs.
Purpose
Provide a reporting-friendly view of exchange rates, exposing both direct and inverse currency pairs in a single, consumable dataset.
This model standardizes exchange rate data so downstream models and reports can convert between currencies without needing to handle pair directionality or rate inversion logic.
Business Logic
- Start from the Exchange Rates fact table
- Resolve currency pairs into base and quote currencies
- Translate internal currency identifiers into ISO currency codes
- Derive ISO week number from the rate date
- Generate inverse rates automatically:
- Swap base and quote currencies
- Invert the exchange rate value
- Combine direct and inverse rates into a single result set
Output Contract
Definitions
| Column | Description |
|---|---|
| date | Date of the exchange rate (YYYY-MM-DD). Links to Dates |
| weeknum | ISO year-week in YYYYWW format, derived from date |
| base_currency | ISO currency code being converted from |
| quote_currency | ISO currency code being converted to |
| value | Exchange rate value from base_currency to quote_currency |
Sample & Implementation
| date | weeknum | base_currency | quote_currency | value |
|---|---|---|---|---|
| 2025-11-24 | 202548 | EUR | USD | 1.15114435 |
| 2025-11-24 | 202548 | GBP | USD | 1.30904018 |
| 2025-11-24 | 202548 | EUR | GBP | 0.87938046 |
| 2025-11-24 | 202548 | EUR | CHF | 0.93101927 |
| 2025-11-24 | 202548 | USD | CHF | 0.80877716 |
| 2025-11-24 | 202548 | GBP | CHF | 1.0587218 |
| 2025-09-29 | 202540 | EUR | USD | 1.17221272 |
| 2025-09-29 | 202540 | GBP | USD | 1.34264673 |
| 2025-09-29 | 202540 | EUR | GBP | 0.87306117 |
| 2025-09-29 | 202540 | EUR | CHF | 0.93365481 |
Dependencies
- Facts: Exchange Rates
- Semantic Layers: Currency Pairs and Currencies