Search Results fetch_qa_chars




Overview

The APPS.QA_CHARS_API package body is the foundational server-side API supporting Oracle Quality's characteristic (specification) framework. In Oracle EBS 12.1.1 and 12.2.2, a "characteristic" defines a measurable or observable attribute that a Quality collection plan gathers — for example length, color, or a numeric tolerance band. The package encapsulates the metadata that drives how each characteristic is rendered, validated, and interpreted: its datatype, prompt, default value, LOV source, validation SQL, display length, decimal precision, reasonable limits, and mandatory status. Rather than forcing every client to parse these attributes independently, QA_CHARS_API centralizes the logic in a single callable layer. It is classified as an API and is a VALID object owned by the APPS schema, indicating it is a supported, packaged interface rather than a private utility. Because it is not referenced by any other database object but is referenced by twenty other packages, it functions as a shared, convergent dependency within the Quality application stack.

Key Procedures and Functions

The package exposes twenty-six documented procedures and functions. EXISTS_QA_CHARS is a simple existence check for a characteristic identifier. FETCH_QA_CHARS and FETCH_PLAN_CHARS retrieve characteristic definitions at the global level and at the plan-specific level respectively, the latter reflecting overrides captured in plan characteristic rows. The accessor functions DATATYPE, PROMPT, DEFAULT_VALUE, DISPLAY_LENGTH, DECIMAL_PRECISION, LOWER_REASONABLE_LIMIT, UPPER_REASONABLE_LIMIT, DATA_ENTRY_HINT, and MANDATORY_FLAG each surface a single attribute of a characteristic for the calling client. FK_MEANING and FK_LOOKUP_TYPE resolve foreign-key display values and their associated lookup types. HARDCODED_COLUMN, SQL_VALIDATION_STRING, FORMAT_SQL_FOR_VALIDATION, FORMAT_SQL_FOR_LOV, and REMOVE_ORDER_BY_FROM_SQL work together to assemble, sanitize, and adapt dynamic SQL, notably stripping an ORDER BY clause when SQL is reused for validation rather than for a list of values. GET_ELEMENT_ID returns the element identifier associated with a characteristic. Together these routines form the runtime metadata engine of Quality specifications.

Tables Accessed

The package references QA_CHARS, the master characteristic definition table holding datatype, prompt, limits, precision, and default values; QA_PLAN_CHARS, which stores plan-level characteristic assignments and overrides; and PLITBLM, the PL/SQL internal table of lines used when parsing and manipulating multi-line SQL text. It additionally relies on FND_GLOBAL for session context (user, responsibility, application) and on STANDARD for core PL/SQL types. All tables are addressed through public or APPS synonyms.

Usage Notes

QA_CHARS_API is typically invoked indirectly. Oracle Quality forms call it to render characteristic entry fields, apply default values, and enforce validation. Concurrent programs and the Quality results-collection engine consult it to evaluate limit thresholds and mandatory requirements. Custom extensions should call the documented public routines rather than querying QA_CHARS directly, since the package embeds supported formatting and validation conventions. It remains valid across 12.1.1 and 12.2.2, with dependencies limited to standard APPS and SYS objects.