Compartilhar via


ReleaseUpdateDB60_Payroll.updatePayrollWorkerPositionEarningCode Upgrade Script

Applies To: Microsoft Dynamics AX 2012 R3, Microsoft Dynamics AX 2012 R2, Microsoft Dynamics AX 2012 Feature Pack, Microsoft Dynamics AX 2012

Class

ReleaseUpdateDB60_Payroll

Method

updatePayrollWorkerPositionEarningCode

Description

Inserts records in the PayrollWorkerPositionEarningCode table from the DEL_HRPPartyJobTableRelationship table, the DEL_EmplTable table and the PRLEmployeePayElements table. This script also inserts the record in the PayrollWorkerPositionEarningFrequency table.

Affected Modules and Tables

Affected Modules

Payroll

Affected Tables

PAYROLLWORKERPOSITIONEARNINGCODE

PAYROLLWORKERPOSITIONEARNINGFREQUENCY

HCMPOSITION

DEL_HRPPARTYPOSITIONTABLERELATIONSHIP

DEL_EMPLTABLE

PRLEMPLOYEEUSFEDERALTAXSETUP

DEL_HRPPARTYJOBTABLERELATIONSHIP

PRLEMPLOYEEPAYELEMENTS

PRLPAYELEMENTS

Remarks

This upgrade will create record in the PayrollWorkerPositionEarningCode table from the fields in the PRLPayElements table, the PRLEmployeePayElements table and the HcmPosition table. Records in the PayrollWorkerPositionEarningCode table will only be created if the active or expired DEL_HRPPartyTableRelationship record exists that is associated to the specified DEL_EmplTable record. This upgrade will also create multiple versions if there are multiple PRLEmployeePayElements records for one position ID.

Data Migration Section

From Table: HcmPosition

To Table: PayrollWorkerPositionEarningCode

RecId

Position

From Table: PRLPayElements

To Table: PayrollWorkerPositionEarningCode

DEL_MappingRecId

EarningCode

From Table: PRLEmployeePayElements

To Table: PayrollWorkerPositionEarningCode

PayElementDate

ValidFrom

PayElementDate

ValidTo

HourlyRate

Formula

From Table: DEL_EmplTable

To Table: PayrollWorkerPositionEarningCode

Party

Worker

From Table: PayrollWorkerPositionEarningCode

To Table: PayrollWorkerPositionEarningFrequency

RecId

WorkerPositionEarningCode

New Tables or Fields

Table

Field

Extended Data Type

-or- Base Enum

PayrollWorkerPositionEarningCode