When working with MySQL, we might run into “ERROR 1093 (HY000): You can’t specify target table ‘x’ for update in FROM clause”. This error typically occurs when trying to access the outer query table within a subquery in an UPDATE or a DELETE statement. We can’t do this, but there are a few ways that we can rework our query to still get what we need. >>>
Monthly Archives: July 2025
How to Fix Error 1064 When Using ALTER TABLE ADD CONSTRAINT in MySQL
MySQL’s Error 1064 (42000) when using the ALTER TABLE … ADD CONSTRAINT statement could be tricky to fix. It provides very sketchy information regarding the error itself, only directing the user to check the syntax without telling what the syntax issue is. >>>