How can I return false if 0 rows affected with PDO?
I have this method to execute a SQL query,
public function executeSQL($query, $params = array()) {
Please consider
return $stmt->rowCount() > 0;
Try this
Or
return (bool) $stmt->rowCount();