Req #25854 [Opn]: Return value for pg_insert should be resource instead of bool

From: Date: Sat, 31 Mar 2012 05:25:17 +0000
Subject: Req #25854 [Opn]: Return value for pg_insert should be resource instead of bool
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-169067@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=25854&edit=1

 ID:                 25854
 Updated by:         yohgaki@php.net
 Reported by:        kyle at kipr dot org
 Summary:            Return value for pg_insert should be resource
                     instead of bool
 Status:             Open
 Type:               Feature/Change Request
 Package:            PostgreSQL related
 Operating System:   RH9.0 Linux
 PHP Version:        4.3.3
-Assigned To:        
+Assigned To:        yohgaki
 Block user comment: N
 Private report:     N

 New Comment:

OID was always available for old PostgreSQL, but OID can be omitted. 

It's possible to return OID when it's available otherwise return true.


Previous Comments:
------------------------------------------------------------------------
[2003-10-13 14:29:41] kyle at kipr dot org

Description:
------------
Currently, pg_insert() returns a bool rather than a resource. Usually, insert queries return
resources which can be passed to pg_last_oid() for pulling the OID of that insert statement's
created row. However, nothing can really be done with the "true" return value given by
pg_insert(), therefore making it not quite as useful a function as it could be.



------------------------------------------------------------------------



-- 
Edit this bug report at https://bugs.php.net/bug.php?id=25854&edit=1


Thread (5 messages)

« previous php.bugs (#169067) next »