How to find the terminated worker?

Hello,

We had few employees (they were workers and users in DAX) that created Time entries in the Project management and Account module. Seems like they are no longer with the company now and the worker roles have been terminated from DAX and the users have been deleted from DAX.

There are some invoices that show their hourly work but not their name is blank on the invoice reports as they have been terminated. We need to know the names of the invoice reports and I am trying to find the ProjInvoiceEmpl.person in the HCMWorker.recid but it couldn’t find it. I am trying to find out if there any other tables that the worker information is stored as well in addition to HCMWorker table so, I can some how try to pull the info and display their names on the report. Can some one please advise?

Here is how I am trying to find the worker name as of now

DirPersonName::find(DirPerson::find(DirPartyTable::findRec(HcmWorker::find(projInvoiceEmpl.Worker).Person).RecId).RecId).LastName;

Version : DAX 2012 CU3

Thanks,

Dave

If the worker is terminated, then the related employment and worker related positions will be ended, but it will not delete the worker itself.
You can use \Data Dictionary\Tables\HcmWorker\Methods\name method to get the name.

Thanks Kranthi. But what I trying to understand and do is, I need to be able to somehow related from ProjInvoiceEmpl table to the HCMworker table. When an Hour line is invoiced from the Posted project transaction scree the Hour invoice details are stored in the ProjInvoiceEmpl. When an invoice report is generated then I based on the ProjInvoiceEmpl.ProjInvoiceId, I am trying to relate the ProjInvoiceEmpl.Worker == HCMWorker.Recid and it find the record in the HCMWorker and when I call the \Data Dictionary\Tables\HcmWorker\Methods\name() for that record it is reuturning empty. May be I am missing something?

Thanks,
Dave

Sorry, it can’t find the record in the HCMWorker based on the HCMWorker.Recid == ProjInvoiceEmpl.Worker relation.

How these workers are terminated?

HR/Common/Workers/Workers. Select the worker and click on the ‘Terminate’ button from the Worker Tab and then Terminate button.

If so, you should still be having a record in HCMWorker (this was already stated in my previous comment)