Skip site navigation (1) Skip section navigation (2)

Re: Binary data type with other output method

From: Andreas 'ads' Scherbaum <adsmail(at)wars-nicht(dot)de>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Binary data type with other output method
Date: 2007-12-27 15:19:09
Message-ID: 20071227161909.0e4ab24e@iridium.wars-nicht.de (view raw or flat)
Thread:
Lists: pgsql-hackers
On Thu, 27 Dec 2007 08:52:15 -0500 Andrew Dunstan wrote:

> Andreas 'ads' Scherbaum wrote:
> > On Wed, 26 Dec 2007 20:20:59 -0500 Andrew Dunstan wrote:
> >
> > This PHP driver is in use since years, do you really expect they will
> > fix this bug and make thousands of applications fail? Everyone like
> > Mark who posted an example earlier would have to change the PHP code
> > if the variable is now a true/false boolean instead a 't'/'f' string.
> > No, i don't expect a bugfix here. Newer drivers like PDO seems to
> > behave correct but this will not help if you cannot use this driver.
> 
> I don't see why it couldn't be switchable behaviour, just as it is in 
> DBD::Pg.

Maybe because the PHP folks don't care so much? I don't know. Already
discussed this one on IRC but there's not so much love for fixing this
issue, as far as i can see.
Either i got: "MySQL does this right in returning 0/1, so we don't
care" or i got "other drivers fixed this problem, use this one".


> > i considered this one but this would only bring 0/1 as input, not as
> > output values, which is what i want.
> 
> er, what? This domain would have input and output values of 0/1.

Yes, but i will loose 't', 'true', 'f' and 'false', the usual input
values in PostgreSQL beside '0' and '1'. It's not that the people don't
use true/false, they use this a lot. But they expect boolean variable
in PHP working like a bolean column in PG ... without casts, without
extra workarounds in the code.


Kind regards

-- 
				Andreas 'ads' Scherbaum
German PostgreSQL User Group

In response to

Responses

pgsql-hackers by date

Next:From: Tom LaneDate: 2007-12-27 15:37:07
Subject: Unworkable column delimiter characters for COPY
Previous:From: Joris DobbelsteenDate: 2007-12-27 14:42:57
Subject: Re: Sorting Improvements for 8.4

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group