alter table `TEACHER_SERVICE_ITEM` add `OID_CREATED_BY` bigint unsigned, add `LAST_MODIFIED_DATE` timestamp NULL default NULL, add `CONTENT` text, add index (OID_CREATED_BY), add `CREATION_DATE` timestamp NULL default NULL;

alter table `ABSENCE` drop GIVE_CREDITS_IF_CATEGORY_BELLOW_ASSISTANT;
alter table `GRANT_OWNER_EQUIVALENT` drop GIVE_CREDITS_IF_CATEGORY_BELLOW_ASSISTANT;
alter table `SERVICE_EXEMPTION` drop GIVE_CREDITS_IF_CATEGORY_BELLOW_ASSISTANT;

alter table `ANNUAL_TEACHING_CREDITS` drop key OID_EXECUTION_YEAR;


alter table `ANNUAL_TEACHING_CREDITS` add `HAS_ANY_LIMITATION` tinyint(1) default '0';

alter table `TEACHER_SERVICE_ITEM` add `OID_CORRECTED_EXECUTION_SEMESTER` bigint unsigned, add index (OID_CORRECTED_EXECUTION_SEMESTER);
update TEACHER_SERVICE_ITEM set OID_CORRECTED_EXECUTION_SEMESTER=(select OID_EXECUTION_PERIOD from TEACHER_SERVICE where TEACHER_SERVICE.OID=TEACHER_SERVICE_ITEM.OID_TEACHER_SERVICE);
