Hi,
The problem comes from using a placeholder multiple times in a query...
I never had this with other DB systems.
Here is an example to reproduce the error :
This code finds any reservation in conflict with (:begin,:end).
$sql="
Select * from Reservation WHERE (
(Hour_Begin<=:Begin and Hour_End>=:Begin) or
(Hour_Begin<=:Begin and Hour_End>=:End) or
(Hour_Begin>=:Begin and Hour_End<=:End)or
(Hour_Begin<=:Begin and Hour_End>=:End)
)";
$db= new PDO ( "sqlsrv:server=xxx;Database=xxx","xxx","xxx", array () );
$sth=$db->prepare($sql);
$sth->bindValue(':Begin','30-07-2012 08:00');
$sth->bindValue(':End','30-07-2012 17:30');
$ex=$sth->execute();
$arr = $sth->errorInfo();
print_r($arr);
$dr=$sth->fetchAll();
var_dump($dr);
exit;