C# access模糊查询
我用模糊查询类似“000101”的数字,前面四个数字是确定的,后面两个数字是不确定,这样的模糊查询怎么写,我之前写的是"select id from tableA where [cfgInd] like '0001%'",然后发现会找到我不想要的数据出现,我想将后面不确定的字符确认下来是两个字符,而不是多个字符。
这个怎么写?
求大家帮帮忙吧,急求!!!
谢谢啦!!!
[解决办法]
SQL 通配符
http://www.w3school.com.cn/sql/sql_wildcards.asp
select id from tableA where [cfgInd] like '0001[a-z0-9][a-z0-9]'"