How can I SELECT Manage from Person
I try many request but all dosen't work.
-> SELECT manager_name FROM Person AS p WHERE p.id= :current_contact_id (Error)
-> SELECT PERSON as p JOIN Person a m ON m.id=p.manager_id WHERE p.id= :current_contact_id (Error)
-> SELECT manager_id FROM Person AS p WHERE p.id= :current_contact_id (Error)
Could you help me please.
Khalil
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi Guillaume,
Is there a way to find the manager of the manager of a person (N+2) ?
Many thanks for your help.
Sorry, I'm new on this forum and I don't know if I can post a question on an existing discussion.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi
How can I SELECT Manage from Person
I try many request but all dosen't work.
-> SELECT manager_name FROM Person AS p WHERE p.id= :current_contact_id (Error)
-> SELECT PERSON as p JOIN Person a m ON m.id=p.manager_id WHERE p.id= :current_contact_id (Error)
-> SELECT manager_id FROM Person AS p WHERE p.id= :current_contact_id (Error)
Could you help me please.
Khalil
SELECT Person AS p JOIN Person AS m ON m.manager_id=p.id WHERE m.id=:current_id
Thanks, That's save me
I would need this select, but for caller_id. Does exist this possibility please?
there is no caller_id within a person or contact.
The caller_id is a foreign key from ticket class.
I know but what any JOIN or something? :-( I would need to send email notification to manager of caller when a ticket is in status "new".
You can try something like
SELECT M FROM Person AS M JOIN Person AS C ON C.manager_id = M.id WHERE C.id = :this->caller_id
You're awesome! Thank you!
Glad it helped! 😊
Guillaume
Hi Guillaume,
Is there a way to find the manager of the manager of a person (N+2) ?
Many thanks for your help.
Sorry, I'm new on this forum and I don't know if I can post a question on an existing discussion.