Forum Discussion

Ofiro1234's avatar
Ofiro1234
New Member
3 years ago

Path function parent multiple values

Hello everyone
In the organization I work for, an employee can move from one manager to another manager in some period of time, so I need to find a solution that will allow creating a new hierarchy path based on a date. Is it possible?

here is an example:

DateManagerIdPerson Id
01/01/2022 1
01/01/2022    12
01/01/2022    13
01/01/2022    24
02/01/2022    34

for this scenario, I would except to get that path:

PathDateManagerIdPerson Id
101/01/2022 1
1|201/01/2022    12
1|301/01/2022    13
1|2|401/01/2022    24
1|3|402/01/2022    34

The path function doesnt let me build a path because some of my values got more than one parent, like person id '4' in this example.

Thank You.

3 Replies

  • Hey Ofiro1234 ,

     

    you can't create this for a simple reason: it's not possible that a child has multiple parents.

     

    Regards,

    Tom

     

    • Ofiro1234's avatar
      Ofiro1234
      New Member

      Thank you for your response.

      do you know if there is any other solution for this scenario? maybe without the path function.

      • DM_W's avatar
        DM_W
        Frequent Visitor

        Hello did you find a solution? I have the same problem. Some employees belong to 2 different departments so they have 2 managers so they have duplicated values in my table.

        Thank you