mysqli_stmt 方法 bind_param,要求一次性把参数全部传入,相当于参数个数和次序必须是硬编码了,但是实际中不一定可以做得到
比如在做查询时,可能查询语句会这样写
$sql = " select * from mytable where price > 100";
if(....)
    $sql .= " and price < ?";
if(....)
    $sql .= " and createddate < ?";
if(....)
    $sql .= " and employeeid = ?";
......这时应该如何传入参数?
大家不用建议我如何改进 sql 的写法,还将会有其它类似的 sql,我这里只是举个例子,只想知道有什么办法可以动态设置参数谢谢!