raj_2006
11-19-2007, 02:00 AM
Hi all,
I am trying to delete some records from more than one table.But the sql is giving the error.Here is the query
$del=mysql_query("delete from member,idol,habit where member.mid='{$_SESSION['mid1']}' or idol.mid='{$_SESSION['mid1']}' or habit.mid='{$_SESSION['mid1']}'") or die(mysql_error());
If mid=5 then in idol table there is no record containing mid=5.Is it the reason?
Please suggest what I shall do now.
Thanks for your co-operation in advance.
Regards,
Raj
I am trying to delete some records from more than one table.But the sql is giving the error.Here is the query
$del=mysql_query("delete from member,idol,habit where member.mid='{$_SESSION['mid1']}' or idol.mid='{$_SESSION['mid1']}' or habit.mid='{$_SESSION['mid1']}'") or die(mysql_error());
If mid=5 then in idol table there is no record containing mid=5.Is it the reason?
Please suggest what I shall do now.
Thanks for your co-operation in advance.
Regards,
Raj