|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2008-12-12 11:36 UTC] denis at edistar dot com
[2009-01-15 22:30 UTC] andrew at rook dot ca
[2009-02-04 00:43 UTC] matteo at beccati dot com
[2009-03-28 19:09 UTC] mbeccati@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Oct 29 20:00:01 2025 UTC |
Description: ------------ I don't see how to use scrollable cursors with pdo_pgsql Reproduce code: --------------- $db = new Pdo("pgsql:..."); $db->setAttribute(Pdo::ATTR_ERRMODE, Pdo::ERRMODE_EXCEPTION); $res = $db->prepare("SELECT 'row1' UNION SELECT 'row2' UNION SELECT 'row3' UNION SELECT 'row4'", array(PDO::ATTR_CURSOR => PDO::CURSOR_SCROLL)); $res->execute(); var_dump($res->fetch()); // $res->fetch(Pdo::FETCH_NUM, PDO::FETCH_ORI_ABS, 2) won't throw an exception but return false Expected result: ---------------- array('row1') Actual result: -------------- Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[34000]: Invalid cursor name: 7 ERROR: cursor "pdo_pgsql_cursor_00d78a0c" does not exist' in ...