I have created a new database with those tables.

DROP TABLE IF EXISTS ACL_GROUPS;
CREATE TABLE ACL_GROUPS (
  groupid char(30) character set latin1 NOT NULL default '',
  creationtime datetime default '0000-00-00 00:00:00',
  active smallint(6) default '1',
  priority smallint(6) default '1',
  PRIMARY KEY  (groupid)
) TYPE=InnoDB;

--
-- Table structure for table 'ACL_GROUP_LIST'
--

DROP TABLE IF EXISTS ACL_USERS;
CREATE TABLE ACL_USERS (
  groupid char(30) character set latin1 NOT NULL default '',
  userid char(30) character set latin1 NOT NULL default '',
  PRIMARY KEY  (groupid,userid),
  FOREIGN KEY (`groupid`) REFERENCES `ACL_GROUPS` (`groupid`) ON DELETE 
CASCADE
) TYPE=InnoDB;

(there is no data in the tables).

Then when I try to drop a foreign key, I get this error:

mysql> alter table ACL_USERS drop foreign key groupid;
ERROR 1005: Can't create table './irwingrid/#sql-7515_3.frm' (errno: 150)


it is mysql 4.1.
Is this  a known issue ? If I convert the tables to MyIsam and then try to 
drop the key, it works fine.



Irwin Boutboul
Advanced Internet Technology
150 Kettletown Road, B2-N06
Southbury, CT 06488
Phone: 203-486-5614

Reply via email to