I hate to sound like a smartass, but where is your query run?
This will not work, for instance:
$query = mysql_query("SELECT * FROM products WHERE part_num='$part_num'");
$insertquery = mysql_query("insert query here");
$queryvalues = mysql_fetch_array($query);
I know it seems obvious, but I have been known to get ahead of myself at times or depend on a pre-defined query that no longer contains the current values.
shrug It's a place to start.
-Ben