Error Code: 1093 occurs when the following SQL statement is executed:
update car set tag = 1 where id in (select id from car where brand_id=182 and tag=0);
The reason for the error is that the modified table and the queried table are the same table, which is not allowed in MySQL. We can solve this problem by querying again in the middle:
update car set tag = 1 where id in (select id from (select id from car where brand_id=182 and tag=0) As temp);
Read More:
- 1093 – You can’t specify target table ‘table’ for update in FROM clause
- DB2 encountered the problem of sqlcode = 911 lock table when updating record update
- Errors in IntelliJ ieeasql statements and table names in @ table
- Insert into / delete / update / select of SQL Server database table
- Error Code: 1055. Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated
- Syntax error or access violation: 1055 Expression #1 of SELECT list is not in GROUP BY clause and co
- Mysql error when deleting the table structure: Error Code: 1217. Cannot delete or update a parent row: a foreign key constraint fails
- AR# 57595 – Vivado Synthesis – ERROR: [Synth 8-4169] error in use clause: package ‘xxx‘ not found in
- Python learning notes (5) — cross entropy error runtimeerror: 1D target tensor expected, multi target not supported
- Insufficient table space ORA-00604 unable to extend table SYS.AUD by 8192
- If you open the store in iTunes, you will be prompted to solve the 310 error
- For the installation of anaconda3 in manjaro system, after the update (CONDA update — all), the terminal prompts an error and cannot execute CONDA related commands
- DB2 create table error – 104 42601 illegal symbol encountered in SQL statement
- Composer update encountered “Script php artisan optimize handling the post-update-cmd event returne when upgrading laravel
- About error 1005 (HY000) in MySQL: can’t create table ‘_______ ‘(errno: 150) fool’s plan
- An error occurred when opensips started the service“ ERROR:core :db_ check_ table_ Version: invalid version 7 for Table dialog found “
- In the SQL query statement, add the column that does not exist in the table and set the fixed value of the column
- (element UI component table) how to add a style to a table
- 1072 – Key column ‘xxx_id’ doesn’t exist in table
- Solution to error 1452: cannot add or update a child row: a foreign key constraint failures in MySQL