Oracle migration - Index column prefix
Posted by: KimSeong Loh
Date: June 07, 2005 08:31PM

I got some column prefix in the indexes for non-string index when I try to migrate from Oracle.

Example of Create table output, from Oracle sample schema.

CREATE TABLE `hr`.`employees` (
`employee_id` INTEGER(6) NOT NULL AUTO_INCREMENT,
`first_name` VARCHAR(20) NULL,
`last_name` VARCHAR(25) NOT NULL,
`email` VARCHAR(25) NOT NULL,
`phone_number` VARCHAR(20) NULL,
`hire_date` DATETIME NOT NULL,
`job_id` VARCHAR(10) NOT NULL,
`salary` DECIMAL(8, 2) NULL,
`commission_pct` DECIMAL(2, 2) NULL,
`manager_id` INTEGER(6) NULL,
`department_id` INTEGER(4) NULL,
PRIMARY KEY (`employee_id`),
INDEX `emp_department_ix` (`department_id`(22)),
UNIQUE INDEX `emp_email_uk` (`email`(25)),
INDEX `emp_job_ix` (`job_id`(10)),
INDEX `emp_manager_ix` (`manager_id`(22)),
INDEX `emp_name_ix` (`last_name`(25), `first_name`(20)),
CONSTRAINT `emp_manager_fk` FOREIGN KEY `emp_manager_fk` (`manager_id`)
REFERENCES `hr`.`employees` (`employee_id`)

)
ENGINE = INNODB;



Edited 2 time(s). Last edit at 06/08/2005 08:10AM by Edwin DeSouza.

Options: ReplyQuote


Subject
Written By
Posted
Oracle migration - Index column prefix
June 07, 2005 08:31PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.