Search Results get_w2_state_uin
Overview
APPS.HR_US_W2_REP is a PL/SQL package in Oracle E-Business Suite that provides the data access layer for United States W-2 payroll reporting. Declared with AUTHID CURRENT_USER, the package exposes a set of functions and procedures that return the individual values and parameters required to render W-2 forms and their associated federal, state, and county wage and tax reporting data. Rather than performing report formatting itself, the package acts as a reusable repository of W-2 calculation and lookup logic that other payroll reporting objects invoke. The package header carries a header revision tag (pyusw2pg.pkh) and the source is maintained by Oracle payroll development; the current documented version reflects maintenance through the 12.1.1 and 12.2.2 release lines. The package is a long-lived, heavily referenced component — the documentation records that it is referenced by 35 other packages — which underscores its role as a foundational utility for US statutory year-end payroll processing.
Key Procedures and Functions
ETRM documents 28 procedures and functions within the package. The following are explicitly listed:
- GET_W2_BOX_15 — returns the value associated with a W-2 Box 15 entry; the function was overloaded and its effective-date default removed in earlier revisions.
- GET_W2_ARCH_BAL — returns archived W-2 balance amounts. Historic change notes show the signature was revised to accept
w2_tax_unit_idandw2_jurisdiction_codeas optional (DEFAULT NULL) parameters. - GET_W2_BAL_AMT — returns a W-2 balance amount.
- GET_W2_TAX_UNIT_ITEM — returns a tax unit reporting item.
- GET_W2_ORGANIZATION_ID, GET_W2_LOCATION_ID, GET_W2_POSTAL_CODE, GET_W2_EMPLOYEE_NAME — return employer/employee identifying attributes used on the form.
- GET_W2_STATE_EIN, GET_W2_STATE_UIN — return state employer identification and state unemployment identification numbers.
- GET_W2_HIGH_COMP_AMT — returns the high compensation amount used in W-2 computations.
- GET_USER_ENTITY_ID, GET_CONTEXT_ID — return reporting context and user entity identifiers.
- GET_TAX_UNIT_ADDR_LINE, GET_TAX_UNIT_BG — return tax unit address lines and background information.
- GET_PER_ITEM, GET_STATE_ITEM — return person-level and state-level reporting items.
- GET_LEAV_REASON — returns the termination reason meaning (added to fix a prior defect).
- GET_COUNTY_TAX_INFO — procedure returning county tax information.
- GET_AGENT_TAX_UNIT_ID — procedure supporting agent reporting enhancement.
Tables Accessed
The package reads from a defined set of tables accessed through APPS synonyms. Archival and balance data is sourced from FF_ARCHIVE_ITEMS, FF_ARCHIVE_ITEM_CONTEXTS, FF_CONTEXTS, FF_DATABASE_ITEMS, and FF_USER_ENTITIES (the Flexfields archived-data structures). Reference and lookup values are drawn from FND_LOOKUP_VALUES. Location and organization attributes come from HR_LOCATIONS_ALL and HR_ORGANIZATION_INFORMATION, with address data from PER_ADDRESSES. Employee and assignment data is sourced from PER_ALL_PEOPLE_F and PER_ALL_ASSIGNMENTS_F, while payroll context comes from PAY_PAYROLL_ACTIONS, PAY_ASSIGNMENT_ACTIONS, PAY_JOB_WC_CODE_USAGES, and PAY_US_COUNTY_TAX_INFO_F. These tables supply the federal, state, and county wage/tax values required for W-2 generation.
Usage Notes
HR_US_W2_REP is typically invoked indirectly rather than called by end users directly. It is consumed by the US Payroll year-end W-2 report and archive programs, by the W-2 forms and reconciliation concurrent programs, and by other reporting packages that need consistent W-2 value resolution. Because it is referenced by 35 other packages, customizations should avoid modifying the package and should instead call its public functions. The AUTHID CURRENT_USER declaration means the package executes with the privileges of the calling user, so callers must have appropriate grants on the underlying tables and synonyms. Custom year-end reports and interfaces can invoke the GET_W2_* functions to obtain standardized W-2 values without reimplementing payroll business rules, and the GET_W2_ARCH_BAL function in particular supports retrieval of archived balances filtered by tax unit or jurisdiction.
-
PACKAGE: APPS.HR_US_W2_REP
12.1.1
-
PACKAGE: APPS.HR_US_W2_REP
12.2.2
-
PACKAGE BODY: APPS.HR_US_W2_REP
12.1.1
-
PACKAGE BODY: APPS.HR_US_W2_REP
12.2.2