tableOk so what I want to do is the following
I have multiple tables on one database in mysql
database1
table1
table2
table3
table4
table5
each table has a column id
for every id matched i want to delete that row. so delete 954001 row in every table. What is the best way to do this WITHOUT killing my database. Btw all ids match across the board.
<?php
// get value of id that sent from address bar
$customer_id=$_GET['id'];
$id=$_GET['id'];
// Delete data in mysql from row that has this id
$sql="DELETE FROM teable_users WHERE customer_id = $customer_id;
DELETE FROM table_parties WHERE id = $id;
DELETE FROM table_weddings WHERE id = $id;
DELETE FROM table WHERE id = $id;
DELETE FROM table_request_client WHERE id = $id;
DELETE FROM table_requests WHERE id = $id;
DELETE FROM table_users WHERE id = $id;";
$result=mysql_query($sql);
// if successfully deleted
if($result){
echo "Deleted Successfully";
echo "<BR>";
echo "<a href='text.php'>Back to Event Manager</a>";
}
else {
echo "ERROR";
}
// close connection
mysql_close();
?>