I have a table with hold information of employees who left 6 months ago. Now i wish to update the leave dates of these employees with information provided in another table.
ie the SOURCE table is EMPLOYEE_STAGING ( which hold the employee who left 6 months back)
EMPLOYEE_CREDENTIALS table( hold the current info)
here is what i need to perform
UPDATE EMPLOYEE_STAGING ES
SET LEAVE_DATE= (SELECT LEAVE_DATE FROM EMPLOYEE_CREDENTIALS EC WHERE EC.EMP_ID=ES.EMP_ID)
I hope i am able to convey what i am trying to accomplish using the above code although it might be totaling wrong.
I also want to have this job of updating schedueld on a weekly basis.
How can i do so?