如下:下面两个`sid`=1列后的`sname` 列 我都有中文在数据库里,为啥在这不显示出来,直接空着的?
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 30
Server version: 5.1.30-community MySQL Community Server (GPL)Type 'help;' or '\h' for help. Type '\c' to clear the buffer.mysql> use test
Database changed
mysql> select*from stu;
+------+--------+
| sid | sname |
+------+--------+
| 1 | |
| 1 | |
| NULL | NULL |
| 2 | asd |
+------+--------+
4 rows in set (0.00 sec)mysql>
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 30
Server version: 5.1.30-community MySQL Community Server (GPL)Type 'help;' or '\h' for help. Type '\c' to clear the buffer.mysql> use test
Database changed
mysql> select*from stu;
+------+--------+
| sid | sname |
+------+--------+
| 1 | |
| 1 | |
| NULL | NULL |
| 2 | asd |
+------+--------+
4 rows in set (0.00 sec)mysql>
解决方案 »
- 关于mysql怎么取表或者视图最后一条数据,不能使用ID
- 我在Windows下安装了MySQL5,数据库的储存路径在哪啊?
- 求助:winform程序用的mysql数据库如何生成不用在使用端安装mysql服务器的程序
- 索引的问题。
- 一个查询问题
- 如何进行多表查询
- 模糊搜索符合oh my god的数据,越匹配的越靠前?100分随后补齐
- 菜鸟问题,我装了mysql 4.0.21后,怎么看不到mysql这个数据库
- 对于POSTGRES数据库表进行select操作时,如何将两个field合并成一个field
- 在MYSQL里,Lock Tables 与Unlock Tables怎么使用?!(举例)
- Mysql自动对update加锁,那么乐观锁在mysql是怎么实现的?困扰我很久了!!
- 分组后合并多行的 sql 怎么写?大神请进。。。。。
select*from stu;试试
gbk试了下不行,utf8也试了一下,也不行0.0
2、CREATE DATABASE 库名CHARACTER SET 'utf8' COLLATE 'utf8_general_ci';
3、CREATE TABLE表名(...) ENGINE= MYISAM CHARACTER SET utf8 ;
show create table 看一下,是不是表的字符集本身就不支持中文。然后再看数据库的字符集。最后再查看你使用的终端的字符集。