sql_mode 系统管理员 2021-09-23 02:20 273阅读 0赞 mysql> select @@sql\_mode \-> ; \+——————————————————————————————————————————————-+ | @@sql\_mode | \+——————————————————————————————————————————————-+ | ONLY\_FULL\_GROUP\_BY,STRICT\_TRANS\_TABLES,NO\_ZERO\_IN\_DATE,NO\_ZERO\_DATE,ERROR\_FOR\_DIVISION\_BY\_ZERO,NO\_AUTO\_CREATE\_USER,NO\_ENGINE\_SUBSTITUTION | \+——————————————————————————————————————————————-+ 1 row in set mysql> set sql\_mode =’STRICT\_TRANS\_TABLES,NO\_ZERO\_IN\_DATE,NO\_ZERO\_DATE,ERROR\_FOR\_DIVISION\_BY\_ZERO,NO\_AUTO\_CREATE\_USER,NO\_ENGINE\_SUBSTITUTION’; Query OK, 0 rows affected mysql> select @@sql\_mode; \-> select @@sql\_mode; 1193 - Unknown system variable ‘sql\_mode;’ mysql> select @@sql\_mode; \+————————————————————————————————————————+ | @@sql\_mode | \+————————————————————————————————————————+ | STRICT\_TRANS\_TABLES,NO\_ZERO\_IN\_DATE,NO\_ZERO\_DATE,ERROR\_FOR\_DIVISION\_BY\_ZERO,NO\_AUTO\_CREATE\_USER,NO\_ENGINE\_SUBSTITUTION | \+————————————————————————————————————————+ 1 row in set mysql>
还没有评论,来说两句吧...