Wednesday, 21 August 2013

How to resolve this error "MySQL Error: 1109 (Unknown table 'table_name' in MULTI DELETE)"?

How to resolve this error "MySQL Error: 1109 (Unknown table 'table_name'
in MULTI DELETE)"?

I'm using PHP and MySQL(Server version: 5.5.31-0ubuntu0.12.04.2) for my
website when I run the following query it's giving me the above error. I
couldn't get any clue behind this error. Can anyone help me in resolving
this error and suggesting the changes if any to my existing query? For
your reference I'm writing my query below:
DELETE
ABC.theory_sheet_set,
ABC.theory_sheet_questions
FROM
ABC.theory_sheet_set AS theory_sheet_set,
OCN.theory_sheet_questions AS theory_sheet_questions
WHERE
theory_sheet_set.theory_sheet_set_id =
theory_sheet_questions.theory_sheet_set_id
AND theory_sheet_set.theory_sheet_id=".$theory_sheet_id
The error it gives is as follows:
MySQL Error: 1109 (Unknown table 'theory_sheet_set' in MULTI DELETE)
Session halted.
My database name is ABC. Actually all the table names are valid and all
the tables involved in this query are present there into the database. Can
you please help me in resolving this issue? Thanks in advance.

No comments:

Post a Comment