Closed
Description
That drove me ABSOLUTE NUTTTTS!!! After making this call with $params array of int
values, those values become strings.
var_dump($params); // array(2) { [0]=> int(6609) [1]=> int(6664) }
$adapter->fetchAll($sql, Db::FETCH_ASSOC, $params);
var_dump($params); // array(2) { [0]=> string(4) "6609" [1]=> string(4) "6664" }
It's crazy, even if I do array_values I end up with the same shit:
$adapter->fetchAll($sql, Db::FETCH_ASSOC, array_values($params));
Can we not use references in such calls? When we use references in C, does it actually help with anything or are they treated by zend compiler in the same way they are in PHP? Because if they do – it might be completely pointless. This might be a really dumb question, sorry, I'm taking the shot.