我是新人,求教复杂查询 select * from where or 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 如果全部为空则不执行。if (edit1.text != "" or edit2.text != "" or.........edit15.text != ""){ select * from yourtable where condition1 = edit1.text or condition2 = edit2.text or ......condition15 = edit15.text} elsereturn;我的是C里面的语法。。你改成PHP专用的。。估计就差不多了~~ 1-------if (edit1.text != "" ){ cond1 = "cond1 = '".cond1."'";}else{ cond1 = "1";}if (edit2.text != "" ){ cond2 = "cond2 = '".cond2."'";}else{ cond2 = "1";}.....strsql = "select .... where ".cond1." or ".cond2."....... strsql = "select .... where ".cond1." and ".cond2."....... 关于openssl求大牛 php正则提取数据 IF 结构设计问题,乱了! php 高手进呀 检测同一用户不能同时在线问题~~~~~!20回送 mysql难题 php特殊符号“-” 问题 apache+php+mssqlserver2000配置问题 我的第一个php网站。 问个关于数组传值的问题,在线等~~ 已建数据库,如何导入建表文件? 我是新手,求教复杂查询问题
if (edit1.text != "" or edit2.text != "" or.........edit15.text != "")
{
select * from yourtable where condition1 = edit1.text or condition2 = edit2.text or ......condition15 = edit15.text
}
return;我的是C里面的语法。。你改成PHP专用的。。估计就差不多了~~
cond1 = "cond1 = '".cond1."'";
}else{
cond1 = "1";
}
if (edit2.text != "" ){
cond2 = "cond2 = '".cond2."'";
}else{
cond2 = "1";
}.....
strsql = "select .... where ".cond1." or ".cond2.".......