I am getting an error while executing the following query.
sql statements

$sql = "SELECT DISTINCT `id_row`, `input_date` FROM `table_name` WHERE `active`=? AND `user`=? AND `id_row` IN (?,?) ORDER BY `id_row` DESC LIMIT ?, ?";

Executing this code directly in PHPMyadmin database by replacing the parameters with the actual values works fine. I also validated the query online with some tools.

Output of the parameter values with var_dump($params)

array(6) { [0]=> int(1) [1]=> int(10) [2]=> int(27) [3]=> int(17) [4]=> int(0) [5]=> int(10) }

These are 6 parameter values, as required by the query.

if($stmt=$this->pdo->prepare($sql)){
  if($stmt->execute($params)){ // The error occurs here. 
  ...
  }
}

The error log:
... check the manual that corresponds to your MySQL server version for the right syntax to use near ''0', '10'' at line 1 in C:...
I couldn’t figure out what was wrong. Do you have any advice?