MySQL表别名的另类用法

复制lock tables `categories` write,表别名 `categories` as `c1` write, `categories` as `c2` write; update `categories` as `c1`, `categories` as `c2` set `c1`.`parent_id` = `c2`.`parent_id` where `c1`.`parent_id` = `c2`.`cat_id` and `c2`.`cat_id` = $cat_id; delete from `categories` where `cat_id` = $cat_id; unlock tables; 1.2.3.4.5.6.7.8.
本文地址:http://www.bzve.cn/news/00b8199918.html
版权声明
本文仅代表作者观点,不代表本站立场。
本文系作者授权发表,未经许可,不得转载。