- 数据库
浅淡SQL中where 1=1和0=1的作用
时间:2010-12-5 17:23:32 作者:IT科技类资讯 来源:IT科技 查看: 评论:0
内容摘要:复制stringMySqlStr=”select*fromtablewhere”; if(Age.Text.Lenght>0) {

浅淡
复制 string MySqlStr=”select * fromtablewhere”; if(Age.Text.Lenght>0) { MySqlStr=MySqlStr+“Age=“+“Age.Text“; } if(Address.Text.Lenght>0) { MySqlStr=MySqlStr+“and Address=“+“Address.Text“; } 1.2.3.4.5.6.7.8.9.10.11.12.