Deleting rows from different tables

Posted by Ross on Stack Overflow See other posts from Stack Overflow or by Ross
Published on 2010-04-02T17:01:56Z Indexed on 2010/04/02 17:03 UTC
Read the original article Hit count: 198

Filed under:
|
|

Here is what i'm trying to do:

Delete the project from projects table and all the images associated with that project in the images table

Lets say $del_id = 10

DELETE FROM projects, images WHERE projects.p_id = '$del_id' AND images.p_id = '$del_id'

What is wrong with this query

© Stack Overflow or respective owner

Related posts about mysql

Related posts about php