I have an Employee table which has a field called
" Employee_list "
The structure is
Deptno Deptname Employee_List
This field has all the employee ids working a specific department stored in it separated by commas .
The data in Employee_list field is like 101 , 102, 103, 104 ...etc
The data in the current table is
Deptno Deptname Employee_List
100 Accounting 101,102,103,104
200 Sales 201,202,203,204
I would like to separate the employees from the Employee_List field and report them as individual employee ids in a separate view
The structure of the new view is
Deptno Deptname Emp_id
100 Accounting 101
100 Accounting 102
100 Accounting 103
How do I do that ? Please suggest
" Employee_list "
The structure is
Deptno Deptname Employee_List
This field has all the employee ids working a specific department stored in it separated by commas .
The data in Employee_list field is like 101 , 102, 103, 104 ...etc
The data in the current table is
Deptno Deptname Employee_List
100 Accounting 101,102,103,104
200 Sales 201,202,203,204
I would like to separate the employees from the Employee_List field and report them as individual employee ids in a separate view
The structure of the new view is
Deptno Deptname Emp_id
100 Accounting 101
100 Accounting 102
100 Accounting 103
How do I do that ? Please suggest