Yeah, this is something that is commonly done in php...
Basically, you would need to select a specific record, so you need a unique index key to select on (like a primary key for example)
// Setup your query
$qry = "SELECT * FROM table_name WHERE unique_id = '$id'";
// Run your query
$result = mysql_query($qry);
// Put your results into an array
$data = mysql_fetch_array($result);
// Then output the data however you want depending on what your fielnames are...
echo $data['id']."<BR>";
echo $data['productname']."<BR>";
echo $data['productprice']."<BR>";
echo $data['productqty']."<BR>";
echo $data['productcolor']."<BR>";
Of course this is simplistic, but you get the point (I hope)
The way your data would be changed is by just passing a new $id to the page via a GET or POST method.
Doing it this way would always make your content dynamic. If you wanted to actually write this out to a separate file, that could be done to using the file functions in php. Check the manual for details...