Search Results convert_global_amount
Overview
EDW_CURRENCY is a currency conversion utility package that resides in the APPS schema and forms part of the Oracle EBS Enterprise Data Warehouse (EDW) currency infrastructure. Its central purpose is to convert transaction and base currency amounts into the single global (warehouse) currency configured for the EDW environment. Rather than relying on the operating unit's functional currency, the package aligns all monetary values to a warehouse-level reporting currency, which is essential for consistent, cross-organization analytics across the data warehouse. The package is a heavily depended-upon building block in the ETRM/EDW schema; the documented metadata records that it is referenced by 62 other packages, confirming its role as a shared conversion service rather than a standalone program.
The global currency and its associated rate type are not hard-coded. They are read at runtime from the EDW_LOCAL_SYSTEM_PARAMETERS table, allowing each EDW deployment to nominate its own reporting currency and exchange-rate convention.
Key Procedures and Functions
- CONVERT_GLOBAL_AMOUNT — The primary function and the object the user searched for. It converts a supplied amount into the EDW global currency. It accepts a transaction amount and currency, an optional base amount and base currency, an exchange date, and an optional exchange-rate type. It resolves the target global currency code and rate type by querying EDW_LOCAL_SYSTEM_PARAMETERS, then applies a short-circuit series of tests: if the base amount is already denominated in the global currency it is returned unchanged; likewise if the transaction amount is already in the global currency. When neither amount is supplied it returns NULL, and when no exchange date is provided it returns -1 to signal that conversion could not be performed. Otherwise it delegates the actual conversion to GL_CURRENCY_API.CONVERT_AMOUNT_SQL, first attempting the base amount and then falling back to the transaction amount. A NO_DATA_FOUND handler is declared for the parameter lookup.
- GET_RATE — Retrieves the exchange rate applicable between currencies for a given date and rate type, used to support and validate conversion activity within the EDW currency layer.
- GET_MAU — Supports monetary amount handling within the EDW currency framework, exposed as a documented callable routine alongside the conversion and rate functions.
All three are classified under the generic API category OTHER within the ETRM documentation.
Tables Accessed
- EDW_LOCAL_SYSTEM_PARAMETERS — Read to obtain the warehouse (global) currency code and the associated rate type. This is the configuration source that determines the conversion target.
- GL_CURRENCIES — Accessed through the General Ledger currency infrastructure to support rate and currency-code validation used by the conversion logic.
Usage Notes
EDW_CURRENCY is intended for internal consumption by EDW/ETRM extraction, transformation, and reporting packages rather than by interactive forms. The high inbound reference count (62 packages) indicates it is invoked programmatically during data warehouse loads and currency normalization routines, where each fact or amount must be restated in the global currency. Because the global currency is parameter-driven, the same package works across deployments without code changes. Developers integrating with it should note the sentinel return values: NULL when both inputs are absent, and -1 when conversion is impossible due to a missing exchange date or unresolvable rate, so calling code must handle these outcomes explicitly rather than assuming a numeric result.