还有个问题:
name like '$name%'and company like '%$company%'
在这个逻辑与运算中,如果$name 或者 $company中又一个为空,会出现什么结果?允许吗?
这是我输出我的查询语句的结果:
select cardid,company,name from namecard where name like '于杰%' and company like '%%' and c_telephone like '%' and address like '%%'
在这个查询语句中,我的name值是于杰,其他的都为空,只显示%%,
在sql server 应该显示 null 。不知道是和原因?
name like '$name%'and company like '%$company%'
在这个逻辑与运算中,如果$name 或者 $company中又一个为空,会出现什么结果?允许吗?
这是我输出我的查询语句的结果:
select cardid,company,name from namecard where name like '于杰%' and company like '%%' and c_telephone like '%' and address like '%%'
在这个查询语句中,我的name值是于杰,其他的都为空,只显示%%,
在sql server 应该显示 null 。不知道是和原因?
select cardid,company,name from namecard where name like '于杰%';
Lost connection to MySQL server during query
当我不用的时候运行很好,也不出现上述问题了。
Binary运算符载传表中去分大小写,难道就因为这个吗?
我用了一下,没有变化。对了在查询于句中加如SQL_BIG_RESULT 的作用是什么?什么含义?
请指教!谢谢!
SQL_BIG_RESULT它等同于设置tmp_table_size一般是在发生The table is full错误时使用的,像你这种情况有可能是处理时间过长,或返回的记录集过大???呵呵,我也不能确定,最好将
max_allowed_packet
wait_timeout
interactive_timeout
均重设一下试试呢你的数据集有多大呀
看看会不会出问题呢,我也是这样做的,