Cannot connect to mysql delete query to work

I know there are a few questions that fit this, but I'm relatively new to mysql, and I can't get this work to use the auxiliary quests or the USING keyword, plus I find mysql online documents the complete secret.

I started trying to build my DELETE query using the SELECT query as my base and was able to get all the rows that I wanted to delete:

select *
from writings_tags_link
join writing_tags on writing_tags.id = writings_tags_link.tag_id
where writing_tags.tag = 'tag one'

and then just replace everything with DELETE like this:

delete
from writings_tags_link
join writing_tags on writing_tags.id = writings_tags_link.tag_id
where writing_tags.tag = 'tag one'

Both from the error message and from other similar messages that you cannot use 'ON' to join tables into a delete query, you need to use USING or sub query. The query I created using USING returns a really strange error, first the query:

DELETE
FROM writings_tags_link
USING writing_tags_link INNER JOIN writing_tags  
WHERE writing_tags.id = writings_tags_link.tag_id 
AND writing_tags.tag ='tag one'

Error:

#1109 - Unknown table 'writings_tags_link' in MULTI DELETE

, , . / !

, , .

+5
1

USING DELETE JOINs - multi-delete:

DELETE wtl
  FROM WRITINGS_TAGS_LINK wtl
  JOIN WRITING_TAGS wt ON wt.id = wtl.tag_id
 WHERE wt.tag = 'tag one'
+8

All Articles