语句如下
Dim company_tel As String
company_tel = company_tel1.Text
rst.Open "select * from company where company.company_tel1 like '%" + company_tel + "%'", cnn, 1, 3
Dim company_tel As String
company_tel = company_tel1.Text
rst.Open "select * from company where company.company_tel1 like '%" + company_tel + "%'", cnn, 1, 3
解决方案 »
- 设计一个网上论文评价系统:一篇论文需要很多人来评价,一个人要评价很多文章,需要建几张表效率比较高?数据表间的逻辑如何?怎样连结传递数据?
- 这个分组怎么写
- 急!!!如何补空行!!!!
- 请问:“内部错误,构造不完整”是什么意思
- 删除数据时,相关联表影响问题
- 这样锁定会不会出现同时读取一条记录的情况?怎么改?
- mssql2000 like '%欧美%' 可查到纪录 like '%娜%' 查不到 “欧美凯娜”
- SQL 锁问题
- 我的SQL Server的Management服务启动不了! 出现错误!
- 一个关于数据库连接的问题!!!各位都来看看了!!!
- 为什么我用xp_sendmail发送邮件不成功?
- 表里有些记录完全重复,怎样删除相同的只剩下一条?
Dim company_tel As String
company_tel = company_tel1.Text
rst.Open "select * from company where IsNull(company.company_tel1,'') like '%" + company_tel + "%'", cnn, 1, 3
company_tel = company_tel1.Text
rst.Open "select * from company where company.company_tel1 like '%" + company_tel + "%'", cnn, 1, 3
NULL要这样查:
where company.company_tell is null
company_tel = company_tel1.Text
rst.Open "select * from company where company.company_tel1 like '%" + company_tel + "%' or company.company_tel1 is null", cnn, 1, 3
company_tel1 Is null
若为空转为空字串
IsNull(company_tel1,'')