ALTER TABLE `apw_User` CHANGE `address` `address` VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL , CHANGE `city` `city` VARCHAR( 100 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL , CHANGE `state` `state` VARCHAR( 2 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL , CHANGE `zip` `zip` VARCHAR( 16 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL; ALTER TABLE `apw_User` DROP FOREIGN KEY `apw_User_ibfk_1` , ADD FOREIGN KEY ( `state` ) REFERENCES `apw_DState` ( `id` ) ON DELETE SET NULL ON UPDATE CASCADE ;