我有一个表名steady
,我希望得到星期一的所有行,在days
列的内爆值中,但我尝试了但是它没有工作它正在给出响应,
我的代码 - 我尝试了什么
$sew = " SELECT t.* FROM steady t WHERE FIND_IN_SET(Monday, t.days) > 0";
$eeo = mysqli_query($con, $sew);
while($fre = mysqli_fetch_array($eeo)){
$product_id = $fre['product_id'];
var_dump ($product_id); //NO VARDUMP DATA SHOWS HERE.
}
尝试后的反应
mysqli_fetch_array() expects parameter 1 to be mysqli_result, boolean given in C:\xampp\htdocs\b\d\steadysubscribersajax.php on line 163
答案 0 :(得分:2)
查询不正确,请尝试使用以下方法之一:
SELECT * FROM steady WHERE days =" Monday"
SELECT * FROM stable WHERE days IN(" Monday"," Thuesday")