PDO empty result fix