Hi! I’m trying to run a update on an edge given the old and new values of the target on the edge. The use case is to update a reporting manager of all employees from the given ‘old manager’ to ‘new manager’. Here is the query I’m trying to use:
CREATE DISTRIBUTED QUERY Update_Reporting_Manager(VERTEX<EMPLOYEE> oldManager, VERTEX<EMPLOYEE> newManager) FOR GRAPH employee_manager_hierarchy {
fromMgr (EMPLOYEE) = {oldManager};
COMP = SELECT emplyee from EMPLOYEE:emplyee - (REPORTS_TO>:e) - fromMgr
POST-ACCUM e.to_id = newManager.id;
}
It is failing with the compilation error:
no type can be inferred for e.to_id
Does the current version of GSQL support updates to source/ target edge attributes? Please help with the possible ways to achieve this use case