delete from _field where refTable='img'\;
delete from _table where ref ='img'\;

insert into _table values (  'img', 'img', '', '', '', '1', '80x60', '1', '350x350 ', '0', '', '0', '', '', '', '', '0', '', '', '', '', '', '', '', '', '', '', '' )\;
insert into _field values ( 'img-004', 'img', '999', 'ext', 'Ext', '1', '0', '0', '', '0', '0', '', '', '', '')\;
insert into _field values ( 'img-003', 'img', '999', 'legend', 'Legend', '1', '0', '0', '', '0', '0', '', '', '', '')\;
insert into _field values ( 'img-002', 'img', '999', 'refcat', 'Refcat', '1', '0', '0', '', '0', '0', '', '', '', '')\;
insert into _field values ( 'img-001', 'img', '999', 'ref', 'Ref', '1', '0', '0', '', '0', '0', '', '', '', '')\;
insert into _field values ( 'img-005', 'img', '999', 'Flag_censure', 'Flag censure', '1', '0', '0', '', '0', '0', '', '', '', '')\;

CREATE TABLE `img` (
  `ref` bigint(20) NOT NULL auto_increment,
  `refcat` int(11) default '0',
  `legend` varchar(50) default NULL,
  `ext` varchar(4) NOT NULL default '.jpg',
  `Flag_censure` tinyint(4) NOT NULL default '1',
  PRIMARY KEY  (`ref`)
)\;

CREATE TABLE `imgcategories` (
  `ref` int(11) NOT NULL auto_increment,
  `IMGsouscat` int(11) NOT NULL default '0',
  `IMGcat` varchar(100) default NULL,
  `comment` text,
  `Flag_censure` tinyint(1) default '1',
  PRIMARY KEY  (`ref`)
)\;