mysql_query("SELECT *
FROM tab1, tab2
WHERE tab1.id_prova= tab2.id ORDER BY tab1.id ")