英文:
How do I change the properties of a Character-set-server in Amazon LightSales?
问题
我正在使用Amazon LightSale mysql的5.7版本。
我想要更改character-set-server属性,但我不知道如何操作。请帮助我。
英文:
I'm using version 5.7 of Amazon LightSale mysql.
I'd like to change the character-set-server property, but I don't know how. Please help me.
答案1
得分: 0
您可以在使用MySQL客户端连接时使用SET
语句更改服务器系统变量。查看使用mysql
控制台命令的示例,该命令更改了character_set_server
设置:
mysql> SHOW VARIABLES WHERE VARIABLE_NAME = 'character_set_server';
+----------------------+-------+
| Variable_name | Value |
+----------------------+-------+
| character_set_server | utf8 |
+----------------------+-------+
1 row in set (0.00 sec)
mysql> SET character_set_server=latin1;
Query OK, 0 rows affected (0.00 sec)
mysql> SHOW VARIABLES WHERE VARIABLE_NAME = 'character_set_server';
+----------------------+--------+
| Variable_name | Value |
+----------------------+--------+
| character_set_server | latin1 |
+----------------------+--------+
1 row in set (0.00 sec)
英文:
You can change server system variables when connected with a MySQL client with the SET
statement. See the example with the mysql
console command, which changes the character_set_server
setting:
mysql> SHOW VARIABLES WHERE VARIABLE_NAME = 'character_set_server';
+----------------------+-------+
| Variable_name | Value |
+----------------------+-------+
| character_set_server | utf8 |
+----------------------+-------+
1 row in set (0.00 sec)
mysql> SET character_set_server=latin1;
Query OK, 0 rows affected (0.00 sec)
mysql> SHOW VARIABLES WHERE VARIABLE_NAME = 'character_set_server';
+----------------------+--------+
| Variable_name | Value |
+----------------------+--------+
| character_set_server | latin1 |
+----------------------+--------+
1 row in set (0.00 sec)
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论