语句怎么写
如何查询表里A字段的前四个字符是:1001的所有记录
[解决办法]
select * from tablename where left(column_name,4) = '1001 '
[解决办法]
如何查询表里A字段的前四个字符是:1001的所有记录
SELECT * FROM 表 where substring(a,1,4)= '1001 '
[解决办法]
select * from tablename where substring(column_name,1,4) = '1001 '
[解决办法]
都可以。。。。
晕了
[解决办法]
select * from tablename where column_name like "1001% "
[解决办法]
ls的都正解...
[解决办法]
select * from tbName where colName like '1001% '
[解决办法]
select * from tbName where charindex( '1001 ', colName)=1