php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #73036 pg_insert() now returns a resource ID instead of boolean
Submitted: 2016-09-06 21:08 UTC Modified: 2016-10-12 17:12 UTC
From: tony at precisonline dot com Assigned: cmb (profile)
Status: Closed Package: PostgreSQL related
PHP Version: 5.6.25 OS: Windows
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
44 - 30 = ?
Subscribe to this entry?

 
 [2016-09-06 21:08 UTC] tony at precisonline dot com
Description:
------------
---
From manual page: http://www.php.net/function.pg-insert
---
pg_insert() now returns a resource ID instead of boolean
A bug report was marked as closed with this change on 2014-02-16: https://bugs.php.net/bug.php?id=25854

Test script:
---------------
$conn = pg_connect($connString);
$insert = array(
	'name' => 'test'
);

$result = pg_insert($conn, 'test', $insert);
var_dump($result);

Expected result:
----------------
bool(true)

Actual result:
--------------
resource(3) of type (pgsql result)

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-10-12 16:23 UTC] cmb@php.net
-Status: Open +Status: Verified -Assigned To: +Assigned To: cmb
 [2016-10-12 16:23 UTC] cmb@php.net
Indeed, the behavior has been changed as of PHP 5.6.0.
 [2016-10-12 17:11 UTC] cmb@php.net
Automatic comment from SVN on behalf of cmb
Revision: http://svn.php.net/viewvc/?view=revision&revision=340460
Log: Fix #73036: pg_insert() now returns a resource ID instead of boolean
 [2016-10-12 17:12 UTC] cmb@php.net
-Status: Verified +Status: Closed
 [2016-10-12 17:12 UTC] cmb@php.net
This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation better.
 [2020-02-07 06:06 UTC] phpdocbot@php.net
Automatic comment on behalf of cmb
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=b18e6c19c91fd4ba162fd08913e120258238a7f2
Log: Fix #73036: pg_insert() now returns a resource ID instead of boolean
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed May 01 18:01:31 2024 UTC