If you are working with mysql, you have to drop the () chars in the select, example:
mysql_query("INSERT INTO table1 SELECT * FROM table2 WHERE ID=$last")
Ah, you have to select a distinct table when doing this insert of select, you cannot insert the values of one table to the same table, so, to get a row and insert it again with changed values, the best way is get the data and insert it again:
$qr = mysql_query("SELECT * FROM table1 WHERE ID=$last");
$data = mysql_fetch_object($qr);
$data->name = "new name"; // <-- VALUE CHANGED
$query = "INSERT INTO table1 values ($data->name, .... )";
mysql_query($query);