I’m trying (once again) to delete from multiple tables which are linked by the same primary id.
DELETE
GAME_CONFIG_INITIAL_BUILDINGS.*,GAME_CONFIG_INITIAL_LAND.*,GAME_CONFIG_INITIAL_RESOURCES.*
FROM
GAME_CONFIG_INITIAL_BUILDINGS,GAME_CONFIG_INITIAL_LAND,GAME_CONFIG_INITIAL_RESOURCES
WHERE GAME_CONFIG_INITIAL_LAND.game_config_id=GAME_CONFIG_INITIAL_RESOURCES.game_config_id AND GAME_CONFIG_INITIAL_RESOURCES.game_config_id=GAME_CONFIG_INITIAL_BUILDINGS.game_config_id AND GAME_CONFIG_INITIAL_RESOURCES.game_config_id='1'
What I have works, but looking at the manual I think there is an easier way with the ‘USING’ clause. I just can’t get it to work like the syntax suggests:
DELETE [LOW_PRIORITY] [QUICK] [IGNORE]
FROM tbl_name[.] [, tbl_name[.]] …
USING table_references
[WHERE where_condition]
Am I reading this wrong?
Is there a quicker way of getting what I want done without so much garbage in my clause?