参数:
$params = 2826558; # Necessary Object
$params = array(2826558,2677805,2636005); # NULL
执行代码:
$data = $this->DQL_selectAllByCampaign_id()
->execute( array($params) )
->fetchAll();
var_dump( $data );
SQL查询:
$this->DQL_selectAllByCampaign_id = $this->conn->prepare(
"SELECT * FROM `banner` WHERE `campaign_id` IN (?)"
);
如果$params
是 Integer,则返回必要的 Object。如果$params
是数组,则返回 NULL。
毕竟,事实上它应该工作......我该怎么做?