Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

displaying employee job title on form

(0) ShareShare
ReportReport
Posted on by 1,536

hi expert, i want to display employee job title (designation) on my custom form, the data coming from two different tables, hcmworkerposition details table and premployeementinformation,

i just add both data set on my custom form data set, and set property for join property on form for table HmcworkerPosition toPremploymentInformation, also add control field employee position on form and reference data source hcmworker position table,

but the data is not coming accurate..

please guide me.

Regards.

*This post is locked for comments

  • Verified answer
    Martin Dráb Profile Picture
    Martin Dráb 231,407 Most Valuable Professional on at
    RE: displaying employee job title on form

    Please define your criteria exactly. For example, if you look for primary positions only, you may get no results, because no one must be set at primary. Unfortunately I can't tell you what your business requirements are.

    Then tell us what problem you have with implementing your requirement. Do you understand how to write queries and use display methods?

  • munsif Profile Picture
    munsif 1,536 on at
    RE: displaying employee job title on form

    ok , but if i want to get single primary position for an employee and then want to display his/her desgination, so how it can ,while my custom table have only relation with HcmWorker table,

    Regards Dear Martin.

  • Suggested answer
    Martin Dráb Profile Picture
    Martin Dráb 231,407 Most Valuable Professional on at
    RE: displaying employee job title on form

    One employee can have multiple positions. If you want a single title, you must somehow pick just a single position.

    Either you need some extra information in your table (maybe position ID). you have to choose the positions by some business logic (e.g. to take the primary one or a random one if none is primary).

  • munsif Profile Picture
    munsif 1,536 on at
    RE: displaying employee job title on form

    thankx for so much cooperation  guidance once agian,, table have relationship with HcmWorker through EmpIoyeeid,i.e customTable.Employeeid==Hcmworker.PersonalNumber

  • Martin Dráb Profile Picture
    Martin Dráb 231,407 Most Valuable Professional on at
    RE: displaying employee job title on form

    Arbitrary field names don't say much. Please tell us about logical relations of your table to other tables.

  • Faqruddin Profile Picture
    Faqruddin 1,879 on at
    RE: displaying employee job title on form

    Dear Rehman - Please call the display method in your custom form and write the code for join the two tables. I'm sharing my sample code and replace the code with your tables..

    display ItemGroupId itemGroupId()

    {

       InventItemGroupItem inventItemGroup;

       select ItemGroupId from inventItemGroup where inventItemGroup.ItemId == this.ItemId

            &&  inventItemGroup.ItemDataAreaId  == this.dataAreaId;

       return inventItemGroup.ItemGroupId;

    }

    Best Regards,

    Faqru Shaik

  • munsif Profile Picture
    munsif 1,536 on at
    RE: displaying employee job title on form

    thanks martin for you kind and valuable relay as always,actually the form on which i want to display employee designation as customized table not standard,and having fields

    EMPLOYMENTTYPE EARNINGRULECODE BENDEDRULECODE PAYGROUPCODE ENTITLEMENTRULECODE BASICSALARY EMPLOYEEID DAILYWORKINGHOURS PAYMENTMETHOD CURRENCY STARTDATE ENDDATE SALARYSTATUS DIMENSION EMPLOYEENAME GENERATIONTYPE REFRECID DATAAREAID RECVERSION PARTITION RECID,

    and i want to make relationship of this table to a table (HcmpoistionDetail) or any other which have employee designation ,so how it can.

    Regards.

  • Suggested answer
    Martin Dráb Profile Picture
    Martin Dráb 231,407 Most Valuable Professional on at
    RE: displaying employee job title on form

    If you want a solution for standard AX, use HcmPositionWorkerAssignment table. You can use its description() method, or join it with HcmPositionDetail and get the description from there.

  • Martin Dráb Profile Picture
    Martin Dráb 231,407 Most Valuable Professional on at
    RE: displaying employee job title on form

    Can you please explain the problem? "data is not coming accurate" isn't very specific. Also, what's the relation between those tables? If you mean some standard table, please give us exact names (my version of AX contains neither HcmWorkerPosition nor PrEmployeementInformation table).

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Tip: Become a User Group leader!

Join the ranks of valued community UG leaders

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,407 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans