[Building Sakai] Unable to delete table during conversion from 2.4 to 2.5.0 script running

aakashsinghal aakash at chs.harvard.edu
Wed Jul 22 06:49:51 PDT 2009


ERROR 1217 (23000): Cannot delete or update a parent row: a foreign key
constraint fails

I am getting this error around line 102 or 103 for the conversion script.
Apparently the table exists from when we first run sakai to have it set up
and everything. And on this part of the script, we have to drop it. So we
decided to try to push each line in and see what happens and this is what
happens.

ERROR 1217 (23000): Cannot delete or update a parent row: a foreign key
constraint fails\
mysql> CREATE TABLE `CHAT2_CHANNEL` (
    -> `CHANNEL_ID` varchar(99) NOT NULL default '',
    -> `CONTEXT` varchar(36) NOT NULL default '',
    -> `CREATION_DATE` datetime default NULL,
    -> `title` varchar(64) default NULL,
    -> `description` varchar(255) default NULL,
    -> `filterType` varchar(25) default NULL,
    -> `filterParam` int(11) default NULL,
    -> `contextDefaultChannel` tinyint(1) default NULL,
    -> `ENABLE_USER_OVERRIDE` tinyint(1) default NULL,
    -> `migratedChannelId` varchar(99) default NULL,
    -> PRIMARY KEY  (`CHANNEL_ID`),
    -> KEY `CHAT2_CHNL_CNTXT_I` (`CONTEXT`),
    -> KEY `CHAT2_CHNL_CNTXT_DFLT_I` (`CONTEXT`,`contextDefaultChannel`)
    -> ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
ERROR 1050 (42S01): Table 'chat2_channel' already exists

I even tried to drop it here and it didn't work.

Then I went into the database itself and tried to delete it myself.

mysql> drop table CHAT2_CHANNEL;
ERROR 1217 (23000): Cannot delete or update a parent row: a foreign key
constraint fails

I have made sure I am accessing the right database, Anyone that can help,
thanks!
-- 
View this message in context: http://www.nabble.com/Unable-to-delete-table-during-conversion-from-2.4-to-2.5.0-script-running-tp24606908p24606908.html
Sent from the Sakai - Development mailing list archive at Nabble.com.



More information about the sakai-dev mailing list