1: 2: 3:
1, Testing, 4 // ID, message, page 2, EE!!, 5 // ID, message, page 4, Cool, 4 // ID, message, page
1: 2: 3: 4:
1, http://google.com, Google // id, url, text 2, http://ask.com, ask // id, url, text 3, http://microsoft.com, microsoft // id, url, text 4, http://facebook.com, facebook // id, url, text
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22:
<?php // DATABASE CONNECTION $conn = mysql_connect("localhost","root",""); mysql_select_db("my_database") or die(mysql_error()); $doexe = mysql_query("SELECT * FROM `table_one` ORDER BY `id`"); while ($do = mysql_fetch_array($doexe)) { echo "$do[id] - $do[fname] - $do[lname]<br />"; $findemail = mysql_query("SELECT * FROM `table_two` WHERE `id` = NULL ORDER BY `id`"); while ($a = mysql_fetch_array($findemail)) { echo "ID found in table_two but not found in table_one -- Time to delete: $a[id] <br />"; } } ?>