--TEST-- PDO_DBLIB: driver supports a batch of queries containing SELECT, INSERT, UPDATE, EXEC statements --EXTENSIONS-- pdo_dblib --SKIPIF-- --FILE-- query("create table #php_pdo(id int); "); $db->query( "create proc php_pdo_exec_select_proc as " . "begin " . " insert into #php_pdo values(2), (3), (4); " . " select * from #php_pdo; " . "end; " ); // now lets get some results $stmt = $db->query( "insert into #php_pdo values(1); " . "exec php_pdo_exec_select_proc; " . "drop table #php_pdo; " . "drop procedure php_pdo_exec_select_proc; "); // check results from the insert var_dump($stmt->rowCount()); var_dump($stmt->nextRowset()); // check results from the exec var_dump($stmt->rowCount()); var_dump($stmt->nextRowset()); // check results from the drop table var_dump($stmt->rowCount()); var_dump($stmt->nextRowset()); // check results from the drop procedure var_dump($stmt->rowCount()); var_dump($stmt->nextRowset()); // check that there are no more results var_dump($stmt->rowCount()); var_dump($stmt->nextRowset()); ?> --EXPECT-- int(1) bool(true) int(-1) bool(true) int(-1) bool(true) int(-1) bool(false) int(-1) bool(false)