I found a strange error when deleting a record on the sql command line
The following statement can be executed normally:
delete from t_mid_test_convention where convention_id=33;
But the following syntax error is reported:
delete from t_mid_test_convention as mt2 where mt2.convention_id=33;
mysql> mysql> delete from t_mid_test_convention as mt2 where mt2.convention_id=33; ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'as mt2 where mt2.convention_id=33' at line 1 mysql> delete from t_mid_test_convention as mt2 where mt2.convention_id=33; ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'as mt2 where mt2.convention_id=33' at line 1 mysql> delete from t_mid_test_convention where convention_id=33; Query OK, 0 rows affected (0.20 sec)
Database version:
Server version: 5.5.41-MariaDB MariaDB Server
Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.