51CTO博客开发
转载自http://blog.csdn.net/Adi_liu/archive/2007/12/06/1920606.aspx 如果想查找“_cs”结尾的的账户 select * from [user] where loginname like '%_cs'是不行的,_ 被认为是任意的字符, 所以需要转义字符,有两种写法: select *
一个Book表中字段name有重复的数据,字段type也有重复的数据,统计每类书各有多少本。 sql数据查询统计总数 select count(distinct(字段名)) from table 或 select count(*) from table group by 字段
Copyright © 2005-2025 51CTO.COM 版权所有 京ICP证060544号