MySQL如何中檢視變數及檢視資料庫的編碼
阿新 • • 發佈:2019-01-05
檢視MySQL變數命令:
show variables;
會出現很多的變數,比如連線超時時間、寫入超時時間、MySQL版本等等
檢視資料庫編碼命令:
show variables like "char%";
+--------------------------+--------+
| Variable_name | Value |
+--------------------------+--------+
| character_set_client | utf8 |
| character_set_connection | utf8 |
| character_set_database | utf8 |
| character_set_filesystem | binary |
| character_set_results | utf8 |
| character_set_server | utf8 |
| character_set_system | utf8 |
| character_sets_dir | |
+--------------------------+--------+
8 rows in set (0.00 sec)
可以展示資料庫相關編碼資訊