CREATE TABLE IF NOT EXISTS `ab_bodies` (
  `bodycode` varchar(3) NOT NULL DEFAULT '',
  `bodyname` varchar(64) NOT NULL DEFAULT '',
  `bodynameascii` varchar(64) DEFAULT NULL,
  `email` varchar(70) DEFAULT NULL,
  `bodystatus` varchar(2) DEFAULT NULL,
  `bodycategory` varchar(25) NOT NULL DEFAULT '',
  `bodycategoryorder` int(11) NOT NULL DEFAULT '0',
  `netcomcode` char(1) DEFAULT NULL,
  `countrycode` int(11) DEFAULT NULL,
  `active` enum('yes','no') NOT NULL DEFAULT 'yes',
  PRIMARY KEY (`bodycode`),
  KEY `countrycode` (`countrycode`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 PACK_KEYS=1;

ALTER TABLE `ab_bodies`
  ADD CONSTRAINT `ab_bodies_ibfk_1` FOREIGN KEY (`countrycode`) REFERENCES `countrycodes` (`code`);
