Search Results ak_query_pkg




Overview

AK_QUERY_PKG is a core PL/SQL package in the Oracle E-Business Suite Application Object Library (AK) schema. Its package body, owned by APPS and validated in Oracle EBS 12.1.1 and 12.2.2, provides the runtime query-generation and security-filtering engine used by the Oracle EBS "AK" framework — the metadata layer that powers extensible attributes, descriptive flexfields, region-based query pages, and object-attribute security. In practical terms, the package translates declarative metadata stored in the AK_* tables (objects, attributes, regions, region items, foreign keys, unique keys) into executable SQL against the underlying application tables, while simultaneously enforcing responsibility-level and user-level attribute security.

The package is classified as OTHER in the ETRM metadata rather than as a formal public API, confirming that it is intended for internal use by other AK packages and framework components rather than for direct customer invocation. It is a heavily depended-upon internal utility: the metadata documents that it is referenced by 35 other packages, and it does not itself reference any of those dependents back, indicating a foundational position near the bottom of the AK dependency stack.

Key Procedures and Functions

Two documented program units are exposed by this package body:

Tables Accessed

The package reads (and in some cases writes) a broad slice of the AK metadata schema through APPS synonyms. Object and attribute metadata are sourced from AK_OBJECTS, AK_OBJECT_ATTRIBUTES, and AK_ATTRIBUTES. Region and page layout definitions are read from AK_REGIONS, AK_REGIONS_TL, AK_REGION_ITEMS, AK_REGION_ITEMS_TL, AK_FLOW_PAGE_REGIONS, and AK_FLOW_REGION_RELATIONS. Key structures used to build joins and predicates are drawn from AK_FOREIGN_KEYS, AK_FOREIGN_KEY_COLUMNS, AK_UNIQUE_KEYS, and AK_UNIQUE_KEY_COLUMNS.

Security filtering depends on AK_RESP_SECURITY_ATTRIBUTES, AK_RESP_SECURITY_ATTR_VALUES, and AK_WEB_USER_SEC_ATTR_VALUES, with AK_EXCLUDED_ITEMS applied to suppress items that must never appear in generated queries. The package also references PUBLIC.DBMS_SQL, PUBLIC.PLITBLM, and SYS.V$NLS_PARAMETERS to support dynamic SQL execution, PL/SQL table handling, and NLS-sensitive predicate generation.

Usage Notes

AK_QUERY_PKG is invoked indirectly, typically by the higher-level AK framework packages that render query pages, region-based search screens, and attribute-secured results in Oracle EBS forms, OA Framework pages, and self-service applications. It is not exposed to end users through a standalone concurrent program or a documented public API. Customizations that need to reproduce framework query behaviour should call the supported AK-level APIs rather than this package, since the ETRM classification of OTHER signals that the interface is internal and may shift between releases. The critical operational caveat concerns security: any code path that bypasses GETSECUREDWHERE forfeits the responsibility, user, and exclusion-based protections configured in the AK security tables, so integrators should treat the secured WHERE clause as mandatory rather than optional.