without going into long details, the following script has been working for years. I had to make some changes due to the parent company removing some fields. Now its not working - its not giving me an error, its just not populating the db. i put affected rows to watch, and it yeilds a big fat zero.
i had to remove 2 fields - and as you can see, they balance out (should be 31 fields now). worked last night, had to make some more changes this morning, and boom - not working
I really hate to change this to a bind param, as this was working just fine for what I want it to do.
Please help a blind man LOL I am sure its simple, as I have looked at it too long
foreach($game->game as $g)
echo 'Adding: '.$g->gamename.'<br/>';
$sql = "
INSERT INTO games
$query = $db->prepare($sql);
$g->gameid, $g->gamename, $g->family, $g->familid, $g->productid, $g->genreid, $g->allgenreid, $g->shortdesc,
$g->meddesc, $g->longdesc, $g->bullet1, $g->bullet2, $g->bullet3, $g->bullet4, $g->bullet5, $g->foldername,
$g->price, $g->hasdownload,$g->macgameid, $g->hasvideo, $g->hasflash, $g->hasdwfeature,$g->dwwidth, $g->dwheight,
echo 'affected rows: '.$query->rowcount().'<br/>';
echo "Game insertion error<br/>".$e->getMessage();
}// loop through xml