Search Results convert_currency




Overview

The APPS.EDW_POA_CURR_CONV package body is a small, single-purpose currency conversion utility that forms part of the Oracle EBS Enterprise Data Warehouse (EDW) / Public Sector (POA) reporting infrastructure. Its business function is to translate monetary amounts between currencies for use in EDW-based analytics, extract programs, and reporting routines, rather than to drive transactional subledger processing. The package relies on the central Oracle General Ledger currency engine (GL_CURRENCY_API) to derive the exchange rate that applies for a given currency pair, date, and rate type, and then exposes that rate as a scalar numeric value callers can apply to the amounts they are converting.

The package is documented in the ETRM metadata under APPS ownership with an API classification of OTHER, and it contains a single documented function. It does not reference any APPS synonyms directly and is not referenced by any other documented packages, indicating a leaf-level utility invoked directly by external ETL or reporting code rather than by other PL/SQL APIs within the EBS schema.

Key Procedures and Functions

  • CONVERT_CURRENCY — The only documented function in the package. It accepts the source and target currency codes, the effective rate date, and the rate type, and returns the applicable conversion rate as a numeric value. Internally, it delegates the rate lookup to GL_CURRENCY_API.GET_RATE and stores the result in a package-level variable (l_conversion_rate) that is initialized to 1. If the call to GL_CURRENCY_API.GET_RATE raises any exception, the exception is trapped locally and the rate is reset to 1, producing a neutral (1:1) conversion rather than propagating the error to the caller. The function therefore never raises an unhandled exception to its consumers; a failure simply degrades to a no-conversion result.

Tables Accessed

No tables are documented as being accessed directly by this package through APPS synonyms. The rate information is obtained indirectly via GL_CURRENCY_API.GET_RATE, which in turn reads the Oracle General Ledger currency and daily rate tables (such as GL_DAILY_RATES and related currency definitions and rate type setups) on behalf of this package. Because the package performs no direct SQL against application tables and holds no DML, its data access footprint is entirely read-only and mediated through the GL currency application programming interface.

Usage Notes

EDW_POA_CURR_CONV.CONVERT_CURRENCY is typically invoked from custom PL/SQL, EDW extract programs, or reporting logic where a reporting currency conversion is required and a single scalar rate is more convenient than embedding a direct GL_CURRENCY_API.GET_RATE call. Typical callers pass the from- and to-currency codes, the rate date appropriate to the reporting period, and the applicable rate type (for example, a corporate or spot rate type defined in GL).

Because the function swallows all exceptions and defaults the rate to 1, callers should be aware that a missing or invalid rate definition will silently yield an unconverted amount rather than an error. Reporting logic requiring stricter control over conversion failures may need to validate rates independently or call GL_CURRENCY_API.GET_RATE directly. The package header comment identifies an old revision ($Header: poacurrb.pls 115.2 2003/01/09), indicating the object has remained stable across the 12.1.1 and 12.2.2 releases and is a legacy utility rather than an actively evolving API. It should be used read-only and is safe for concurrent reporting invocations, though the package-level variable l_conversion_rate means the value is session-scoped and not intended for cross-call retention.