MySQL常用操作
1、字符串拼接:
update products a,categorys b set a.categoryNumbers = concat(b.parent,",",a.categoryId,",")
where b.id = a.categoryId
1、字符串拼接:
update products a,categorys b set a.categoryNumbers = concat(b.parent,",",a.categoryId,",")
where b.id = a.categoryId
首先,这片文章纯粹是我的个人经验之谈,适用于我常见的环境及项目中.个人建议,数据库字符集尽量使用utf8(HTML页面对应的是utf-8),以使你的数据能很顺利的实现迁移,因为utf8字符集是目前最适合于实现多种不同字符集之间的转换的字符集,尽管你在命令行工具上可能无法正确查看数据库中的内容,我依然...
--auto-rehash Enable automatic rehashing. One doesn't need to use ...
MySql导入SQL文件: mysql -u root -p <c:\sampledb.sql...
mysql备份语句:E:\MySQL Server 5.0\bin>mysqldump -uroot -padmin --default-character-set=utf8 --opt --extended-insert=false --triggers -R --hex-blob -x s...
指定一个经纬度,给定一个范围值(单位:千米),查出在经纬度周围这个范围内的数据。 经度:113.914619 纬度:22.50128 范围:2km longitude为数据表经度字段 latitude为数据表纬度字段 SQL在mysql下测...
mysql在通过导入sql文件可能会出现下面二个问题: 1.如果sql文件过大,会出现"MySQL server has gone away"问题; 2.如果sql文件数据有中文,会出现乱码 www.2cto.com 解决问题: 问题...