I trying to import a set of profiles from a csv file. I use two tables here (Profiles and Media). Media table is used to link the photos with each of the profiles.
Here is the structure of the profiles table:
CREATE TABLE `Profiles` (
`ID` int(10) unsigned NOT NULL auto_increment,
`NickName` varchar(255) NOT NULL default '',
`Email` varchar(255) NOT NULL default '',
`Password` varchar(32) NOT NULL default '',
`Status` enum('Unconfirmed','Approval','Active','Rejected','Suspended') NOT NULL default 'Unconfirmed',
`Couple` int(10) unsigned NOT NULL default '0',
`Sex` varchar(255) NOT NULL default '',
`LookingFor` set('male','female') NOT NULL default '',
`Headline` varchar(255) NOT NULL default '',
`DescriptionMe` text NOT NULL,
`Country` varchar(255) NOT NULL default '',
`City` varchar(255) NOT NULL default '',
`DateOfBirth` date NOT NULL default '0000-00-00',
`Featured` tinyint(1) NOT NULL default '0',
`DateReg` datetime NOT NULL default '0000-00-00 00:00:00',
`DateLastEdit` datetime NOT NULL default '0000-00-00 00:00:00',
`DateLastLogin` datetime NOT NULL default '0000-00-00 00:00:00',
`DateLastNav` datetime NOT NULL default '0000-00-00 00:00:00',
`PrimPhoto` int(10) unsigned NOT NULL default '0',
`Picture` tinyint(1) NOT NULL default '0',
`aff_num` int(10) unsigned NOT NULL default '0',
`Tags` varchar(255) NOT NULL default '',
`zip` varchar(255) NOT NULL default '',
`EmailNotify` tinyint(1) NOT NULL default '0',
PRIMARY KEY (`ID`),
UNIQUE KEY `NickName` (`NickName`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
The import happens successfully but after a couple of minutes the values for the fields PrimPhoto and Picture are automatically changed to 0.
Here is my insert command:
insert into `Profiles` (`ID`,`NickName`,`Email`,`Password`,`Status`,`Couple`,`Sex`,`LookingFor`,`Headline`,`DescriptionMe`,`Country`,`City`,`DateOfBirth`,`Featured`,`DateReg`,`DateLastEdit`,`DateLastLogin`,`DateLastNav`,`PrimPhoto`,`Picture`,`aff_num`,`Tags`,`zip`,`EmailNotify`)values ('2','AmericaM','email@email.com','098f6bcd4621d373cade4e832627b4f6','Active','0','male','female','Well educated underwater world''s man looking for h','(Binary/Image)','205','CLEVLAND','1979-04-25','0','2005-11-17 12:27:50','2006-01-09 12:30:15','2007-08-20 8:04:35','2007-08-20 8:11:27','2','1','0','female','87467','1');