Search Results get_customer_name




Overview

MRP_MANAGER_PK is a core PL/SQL package in the Oracle E-Business Suite Advanced Supply Chain Planning and material requirements planning modules. Its primary responsibility is to manage the transformation of demand data — sales orders, forecasts, and schedules — into the planning engine's internal interfaces. The package acts as a control layer that computes changes against existing sales orders, applies updates to relief and schedule interface tables, creates forecast demand rows, and drives the in-process explosion of MRP and MDS plans. In addition, it exposes a set of utility functions used to resolve descriptive attributes such as customer names, ship-to and bill-to addresses, project and task identifiers, and unit numbers associated with demand records.

The user search term "get_customer_name" corresponds to the public function get_customer_name, one of the lookup functions that resolve a surrogate identifier into a human-readable value, most often for display or reporting against demand and sales order interface data.

Key Procedures and Functions

The package declares thirteen documented program units. The maintenance procedures include:

  • compute_sales_order_changes — identifies differences between incoming sales order demand and what is already reflected in the planning interface.
  • update_sales_orders — applies those computed changes back to the sales order interface and related staging tables.
  • create_forecast_items — generates forecast item demand records, taking a designator argument to distinguish the forecast source.
  • explode_in_process and mds_explode_in_process — perform in-process explosion of MRP and MDS plans respectively, returning an in-process identifier through an OUT parameter.
  • update_forecast_desc_flex and update_schedule_desc_flex — refresh descriptive flexfield values on forecast and schedule rows, with the schedule variant accepting counts for schedules, forecasts, sales orders, and inter-org demand.

The lookup functions provide resolved descriptive values:

  • get_customer_name(p_customer_id) — returns the customer name for a given customer identifier.
  • get_ship_address(p_ship_id) and get_bill_address(p_bill_id) — return formatted ship-to and bill-to addresses.
  • get_project_id(p_demand_id) and get_task_id(p_demand_id) — return the project and task identifiers associated with a demand record.
  • get_unit_number(p_demand_id) — returns the unit number for a demand.

The package declares PRAGMA RESTRICT_REFERENCES purity constraints (WNDS, WNPS) on the customer, address, project, and task functions, confirming they do not write database state and are safe for use within SQL statements. The unit number function's pragma is commented out for 8.1.5 compatibility.

Tables Accessed

The package reads and writes several planning interface and master tables through APPS synonyms. Customer and party data are resolved from HZ_CUST_ACCOUNTS and HZ_PARTIES. Forecast and schedule demand management relies on MRP_FORECAST_DATES, MRP_FORECAST_ITEMS, MRP_SCHEDULE_DATES, and MRP_SCHEDULE_DESIGNATORS. Sales order processing touches MRP_SALES_ORDER_UPDATES, MRP_SALES_ORDER_UPDATES_S, MRP_SO_LINES_TEMP, and MRP_RELIEF_INTERFACE. Recommendation and form query data reside in MRP_RECOMMENDATIONS, MRP_FORM_QUERY, MRP_FORM_QUERY_S, and MSC_FORM_QUERY, while BOM_CALENDAR_DATES supplies calendar reference data.

Usage Notes

MRP_MANAGER_PK is typically invoked by concurrent programs and planning workflows rather than directly by end users. The sales order change and update procedures execute during demand processing concurrent requests, and the explosion procedures support in-process planning runs. The get_customer_name and address functions are frequently called from custom reports, SQL queries, and form personalizations that need to display a customer name given a stored customer identifier. Because of the WNDS and WNPS pragmas, these functions may be safely embedded in SQL. The package is referenced by two other packages in the application, so changes to its signature should be assessed for downstream impact.