CREATE TABLE `EXPECTATION_EVALUATION_GROUP` (
  `ID_INTERNAL` int(11) NOT NULL auto_increment,
  `KEY_APPRAISER` int(11) NOT NULL default '0',
  `KEY_EVALUATED` int(11) NOT NULL default '0',
  `KEY_EXECUTION_YEAR` int(11) NOT NULL default '0',
  `KEY_ROOT_DOMAIN_OBJECT` int(11) NOT NULL default '1',
  PRIMARY KEY  (`ID_INTERNAL`),  
  UNIQUE KEY `U1` (`KEY_APPRAISER`,`KEY_EXECUTION_YEAR`, `KEY_EVALUATED`),
  KEY `KEY_APPRAISER` (`KEY_APPRAISER`),
  KEY `KEY_EVALUATED` (`KEY_EVALUATED`),
  KEY `KEY_EXECUTION_YEAR` (`KEY_EXECUTION_YEAR`),
  KEY `KEY_ROOT_DOMAIN_OBJECT` (`KEY_ROOT_DOMAIN_OBJECT`)
) ENGINE=InnoDB;

CREATE TABLE `TEACHER_PERSONAL_EXPECTATION_PERIOD` (
  `ID_INTERNAL` int(11) NOT NULL auto_increment,
  `OJB_CONCRETE_CLASS` varchar(250) NOT NULL default '',
  `START_DATE_YEAR_MONTH_DAY` date NOT NULL default '0000-00-00',
  `END_DATE_YEAR_MONTH_DAY` date NOT NULL default '0000-00-00',
  `KEY_EXECUTION_YEAR` int(11) NOT NULL default '0',
  `KEY_DEPARTMENT` int(11) NOT NULL default '0',
  `KEY_ROOT_DOMAIN_OBJECT` int(11) NOT NULL default '1',
  PRIMARY KEY  (`ID_INTERNAL`),
  UNIQUE KEY `U1` (`KEY_DEPARTMENT`,`KEY_EXECUTION_YEAR`, `OJB_CONCRETE_CLASS`),
  KEY `KEY_DEPARTMENT` (`KEY_DEPARTMENT`),
  KEY `KEY_EXECUTION_YEAR` (`KEY_EXECUTION_YEAR`),
  KEY `KEY_ROOT_DOMAIN_OBJECT` (`KEY_ROOT_DOMAIN_OBJECT`)
) ENGINE=InnoDB;
