Skip Menu |

This queue is for tickets about the DBD-Pg CPAN distribution.

Report information
The Basics
Id: 44985
Status: resolved
Priority: 0/
Queue: DBD-Pg

People
Owner: greg [...] turnstep.com
Requestors: fritz.zaucker [...] oetiker.ch
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: 2.13.0



Subject: DBD::Pg 2.0.0 and above: $dbh->{Name} ne $dbh->{pg_db} is not documented
Date: Mon, 13 Apr 2009 00:11:45 +0200 (CEST)
To: bug-DBD-Pg [...] rt.cpan.org
From: Fritz Zaucker <fritz.zaucker [...] oetiker.ch>
Hi, the Database Handle Attributes Name and pg_db return different values: Name gives dbname=MyDatabase whereas pg_db gives MyDatabase for a dbh created with a connect(dbi:Pg:dbname=Mydatabase). In older DBD::Pg versions, namely <2.0.0 andd before, the Name attribute returned the database name without the leading dbname= (it behaved just like pg_db does now). Looking at the documentation of DBI.pm, the current behaviour of Name actually seems to be correct: Name (string) Holds the "name" of the database. Usually (and recommended to be) the same as the "dbi:DriverName:..." string used to connect to the database, but with the leading "dbi:DriverName:" removed. It would be useful to document the difference in behaviour of Name and pg_db in the DBD::Pg documentation. Currently the difference is not visible: Name (string, read-only) Returns the name of the current database. and pg_db (string, read-only) DBD::Pg specific attribute. Returns the name of the current database. May be even a note pointing out the change towards DBD::PG version <= 2.0.0 (where this was changed according to the CHANGES file) would be useful. Cheers, Fritz -- Oetiker+Partner AG tel: +41 62 775 99 03 (direct) Fritz Zaucker +41 62 775 99 00 (switch board) Aarweg 15 +41 79 675 06 30 (mobile) CH-4600 Olten fax: +41 62 775 99 05 Schweiz web: www.oetiker.ch
Thank you, applied some new wording in r12687
Subject: Re: [rt.cpan.org #44985] DBD::Pg 2.0.0 and above: $dbh->{Name} ne $dbh->{pg_db} is not documented
Date: Mon, 13 Apr 2009 21:21:23 +0200 (CEST)
To: Greg Sabino Mullane via RT <bug-DBD-Pg [...] rt.cpan.org>
From: Fritz Zaucker <zaucker [...] oetiker.ch>
On Mon, 13 Apr 2009, Greg Sabino Mullane via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=44985 > > > Thank you, applied some new wording in r12687
Cool! Thanks and cheers, Fritz -- Oetiker+Partner AG tel: +41 62 775 99 03 (direct) Fritz Zaucker +41 62 775 99 00 (switch board) Aarweg 15 +41 79 675 06 30 (mobile) CH-4600 Olten fax: +41 62 775 99 05 Schweiz web: www.oetiker.ch