Updated PDO statement to handle dates in the debug string