30 lines
852 B
MySQL
30 lines
852 B
MySQL
|
|
alter table hrsa_salary_sob_item add income_category varchar2(100);
|
||
|
|
/
|
||
|
|
|
||
|
|
alter table hrsa_salary_sob_item modify income_category default '1';
|
||
|
|
/
|
||
|
|
|
||
|
|
update hrsa_salary_sob_item set income_category = '1' where salary_sob_id IN
|
||
|
|
(select id from hrsa_salary_sob where hrsa_salary_sob.income_category = '1');
|
||
|
|
/
|
||
|
|
|
||
|
|
update hrsa_salary_sob_item set income_category = '2' where salary_sob_id IN
|
||
|
|
(select id from hrsa_salary_sob where hrsa_salary_sob.income_category = '2');
|
||
|
|
/
|
||
|
|
|
||
|
|
update hrsa_salary_sob_item set income_category = '4' where salary_sob_id IN
|
||
|
|
(select id from hrsa_salary_sob where hrsa_salary_sob.income_category = '4');
|
||
|
|
/
|
||
|
|
|
||
|
|
alter table hrsa_salary_sob_item add salary_item_code varchar2(100);
|
||
|
|
/
|
||
|
|
|
||
|
|
update hrsa_salary_sob_item a
|
||
|
|
set ( salary_item_code) = (
|
||
|
|
select code as salary_item_code
|
||
|
|
from hrsa_salary_item b
|
||
|
|
where a.salary_item_id = b.id
|
||
|
|
);
|
||
|
|
/
|
||
|
|
|