I am attempting to create a table with an auto_increment row as the last row of a primary key. It works for a primanry key with two rows but this key has three rows. I am using MySQL 5.5.16 on a local Windows PC. The database engine was installed as part of an XAMPP Lite install. I am using phpMyAdmin Import.
Any help would be appreciated.
Thank You
Here is the error:
CREATETABLEIFNOTEXISTS`mafp_training_sessions` (
`ts_org` smallint( 6)NOTNULL ,
`ts_course_no` int( 11)NOTNULL ,
`ts_session` tinyint( 4)NOTNULLAUTO_INCREMENT ,
`ts_display_seq` tinyint( 4)NOTNULL ,
`ts_description` varchar( 500)NOTNULL ,
`ts_hours` decimal( 4, 1)NOTNULL DEFAULT'0.0',
PRIMARYKEY (`ts_org` ,`ts_course_no` ,`ts_session`)
) ENGINE= InnoDBDEFAULT CHARSET= latin1;
MySQL said:
#1075 - Incorrect table definition; there can be only one auto column and it must be defined as a key
Any help would be appreciated.
Thank You
Here is the error:
CREATETABLEIFNOTEXISTS`mafp_training_sessions` (
`ts_org` smallint( 6)NOTNULL ,
`ts_course_no` int( 11)NOTNULL ,
`ts_session` tinyint( 4)NOTNULLAUTO_INCREMENT ,
`ts_display_seq` tinyint( 4)NOTNULL ,
`ts_description` varchar( 500)NOTNULL ,
`ts_hours` decimal( 4, 1)NOTNULL DEFAULT'0.0',
PRIMARYKEY (`ts_org` ,`ts_course_no` ,`ts_session`)
) ENGINE= InnoDBDEFAULT CHARSET= latin1;
MySQL said:
#1075 - Incorrect table definition; there can be only one auto column and it must be defined as a key