Search Results build_procedure_call




Overview

ECX_UTILS is the shared low-level utility package within the Oracle E-Business Suite ETRM (Electronic Technical Reference Manual) / e-Commerce Exchange (ECX) architecture. In EBS 12.1.1 and 12.2.2, the ECX schema provides the integration infrastructure used by XML Gateway, Oracle iSupplier, Oracle Exchange, and event-driven outbound/inbound transactions. ECX_UTILS acts as the central service layer that these higher-level ECX packages call upon for routine chores: loading message mapping metadata into memory, building dynamic procedure calls for mapping actions, constructing XML DOM nodes, resolving file and path delimiters, raising and formatting errors, and controlling state during concurrent transaction processing.

The package is classified as OTHER rather than a public API, meaning Oracle does not document it as a supported interface for customer extension. Nevertheless, as the metadata notes, it is referenced by 28 other packages, confirming its role as a foundational internal dependency of the ECX runtime. The header declares package-level exceptions such as program_exit, no_seed_data, and documents_under_process (initialized to Oracle error -54), along with global variables used to track retry codes, directionality (SOURCE/TARGET), and object identifiers during a transaction run. These constructs enable controlled propagation of transaction-processing failures.

Key Procedures and Functions

The documented interface exposes 17 procedures and functions:

  • CLOSE_PROCESS — The routine associated with the user's search term. It finalizes a transaction processing cycle, typically releasing the lock or marker that prevents concurrent processing of the same document set, and clearing the documents_under_process state.
  • INITIALIZE — Sets up package globals and working state before a mapping or translation run begins.
  • LOAD_DTD_NODES — Populates in-memory DTD node information used to validate and parse inbound/outbound XML messages.
  • LOAD_PROCEDURE_MAPPINGS — Reads transaction mapping definitions into the dynamic mapping cache.
  • LOAD_PROCEDURE_DEFINITIONS — Loads the metadata describing which PL/SQL procedures implement each mapping action.
  • BUILD_PROCEDURE_CALL — Dynamically constructs the SQL/PLSQL call string for a mapping action, enabling runtime dispatch.
  • GET_TRAN_STAGE_DATA — Retrieves the dynamic stage record (the stage_rec type) describing level, direction, sequence, condition operators, and variable values for a transaction stage.
  • LOAD_MAPPINGS — Loads attribute and level mapping rules into memory.
  • LOAD_OBJECTS — Loads ECX object definitions used during translation.
  • GETLOGDIRECTORY — Returns the EBS log directory path (typically $APPLCSF/$APPLLOG) for ECX processing output.
  • GETFILESEPARATOR — Returns the operating-system file separator character.
  • GETLINESEPARATOR — Returns the platform line terminator used when writing message files.
  • SET_ERROR — Records and formats an error message (into i_errbuf/i_errparams) for concurrent program output.
  • CONVERTPARTYTYPETOCODE — Maps a party type descriptor to its internal ECX code.
  • GETNODEPATH — Returns the XPath-style node path for a given element in a message definition.
  • XMLVERSION — Returns the XML parser version in use (e.g., Oracle XML Parser), useful for diagnostics.
  • CLOBTODOMNODE — Converts a CLOB containing XML into a DOM node object using the XMLDOM and XMLPARSER types.

Tables Accessed

ECX_UTILS reads the configuration tables that define the XML Gateway translation model. These include ECX_OBJECTS and ECX_OBJECT_ATTRIBUTES (objects and their attributes), ECX_OBJECT_LEVELS and ECX_LEVEL_MAPPINGS (hierarchical level definitions), ECX_PROC_MAPPINGS (mapping action to procedure bindings), ECX_ATTRIBUTE_MAPPINGS and ECX_MAPPINGS (attribute-to-column/value translations), ECX_DTDS (DTD metadata), and ECX_TRAN_STAGE_DATA (dynamic stage variables, sequencing, and conditions). It also consults WF_EVENT_T and WF_RESOURCES from the Oracle Workflow schema for event and resource lookups. Dynamic SQL is executed via DBMS_SQL, and PLITBLM supplies the PL/SQL integer-indexed table type used to pass arrays internally.

Usage Notes

ECX_UTILS is not normally invoked directly by end users or forms. It is called internally by the higher-level ECX packages during execution of the XML Gateway concurrent programs (for example, the outbound transaction programs and the inbound translator) and during event processing driven by Oracle Workflow. CLOSE_PROCESS in particular is invoked at the tail end of a transaction processing run to commit state and free the lock established at initialization; a failure to reach CLOSE_PROCESS typically leaves documents flagged as "under process," producing the -54 exception on subsequent runs. Custom developers extending XML Gateway mappings should treat these routines as internal implementation details, relying on supported ECX public APIs rather than calling ECX_UTILS directly, since Oracle may change its signature without notice.