The name path from the top to an employee
For each employee in emp, build the chain of names from the topmost manager down to them, joined by > (e.g. CEO > VP-Eng > EngMgr). Return id and path, ordered by id.
Uzorak očekivanog izlaza
Ovako izgleda ispravan odgovor — broj redaka je njegov vlastiti, ne mora se podudarati s tablicama sheme.
| id | path |
|---|---|
| 1 | CEO |
| 2 | CEO > VP-Eng |
| 3 | CEO > VP-Sales |
Prijavi se da vidiš povijest predaja
PrijavaPrijavi se da koristiš AI mentora
Prijava