I have two tables in Database first is the following : First Table is EMPSHIFT
EmployeeID 01/04/2017 02/04/2017 03/04/2017 04/04/2017 to 30/04/2017 -------------------------------------------------------------------------------- 1 7,6 2 3 4 to end of all employees
second table is SCHEDULEEMPLOYEES
EmployeeID DayDate Shift ------------------------------------ 1 01/04/2017 7,6 1 02/04/2017 5,2 1 03/04/2017 7,6 1 04/04/2017 9 2 01/04/2017 9 2 02/04/2017 3,2 3 01/04/2017 7,6 3 03/04/2017 9 to the end of table data
I want make PL-SQL stored procedure or SQL statement to update the first table data from the second as to set the shift data in the specific column date like for EmployeeID = 1 his shift in 01/04/2017 = 7,6
what i have tried till now is the following What I tried till now
but doesn't work can any help in this