Thursday, 17 January 2019

Title for employee x++

static void empTitle(Args _args)
{
HcmTitle hcmTitle;
HcmWorker hcmWorkerTitle;
HcmPositionDetail hcmPositionDetailTitle;
HcmPosition hcmPositionTitle;
HcmPositionWorkerAssignment workerAssignmentTitle;
str title;

select hcmWorkerTitle
where hcmWorkerTitle.PersonnelNumber == "977" //Personnel Number
join workerAssignmentTitle
where workerAssignmentTitle.Worker == hcmWorkerTitle.RecId
join hcmPositionTitle
where workerAssignmentTitle.Position == hcmPositionTitle.RecId
join hcmPositionDetailTitle
where hcmPositionTitle.RecId == hcmPositionDetailTitle.Position
join hcmTitle
where hcmPositionDetailTitle.Title == hcmTitle.RecId;

title = hcmTitle.TitleId;
info(strFmt("%1", title));
}

No comments:

Post a Comment