quick explination on how you could read a JSON file and append it to a table in the database:
<?php
//connect to DB
$con = mysql_connect("username","password","") or die('Could not connect: ' . mysql_error());
mysql_select_db("product", $con);
//read the json file contents
$jsondata = file_get_contents('empdetails.json');
//convert json object to php associative array
$data = json_decode($jsondata, true);
//get the product details
$code = $data[code];
$name = $data[name];
//insert into mysql table
$sql = "INSERT INTO product(code, name) VALUES('$code', $name)"
if(!mysql_query($sql,$con))
{
die('Error : ' . mysql_error());
}
?>
this should be enough to get you going