Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-30 Thread David Wheeler
On Wednesday, November 27, 2002, at 04:34 PM, David Walker wrote: Does this mean that in the future '342' may not be valid as an insert into a numeric field and that we should be using 342 instead? I didn't see an answer to this question, but I sincerely hope that the answer is no.

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-30 Thread Dave Page
-Original Message- From: David Wheeler [mailto:[EMAIL PROTECTED]] Sent: 30 November 2002 20:18 To: David Walker Cc: PostgreSQL Development Subject: Re: [HACKERS] Boolean casting in 7.3 - changed? On Wednesday, November 27, 2002, at 04:34 PM, David Walker wrote: Does

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-30 Thread Christopher Kings-Lynne
I didn't see an answer to this question, but I sincerely hope that the answer is no. Otherwise, dynamic interfaces are going to have a much harder time. Take DBI (and DBD::Pg), for example. Most DBI users don't specify a data type when using placeholders. Therefore, DBD::Pg (and other

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-28 Thread Ian Barwick
On Thursday 28 November 2002 00:18, Tom Lane wrote: Peter Eisentraut [EMAIL PROTECTED] writes: Ian Barwick writes: Casting integers to boolean (for example, 0::bool) is no longer allowed, use '0'::bool instead. This advice would probably only cause more confusion, because we are now

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-27 Thread David Walker
Does this mean that in the future '342' may not be valid as an insert into a numeric field and that we should be using 342 instead? On Wednesday 27 November 2002 05:07 pm, (Via wrote: Ian Barwick writes: Casting integers to boolean (for example, 0::bool) is no longer allowed, use '0'::bool

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-27 Thread Peter Eisentraut
Ian Barwick writes: Casting integers to boolean (for example, 0::bool) is no longer allowed, use '0'::bool instead. This advice would probably only cause more confusion, because we are now moving into the direction that character strings are no longer acceptable as numeric data. Note that x

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-27 Thread Tom Lane
Peter Eisentraut [EMAIL PROTECTED] writes: Ian Barwick writes: Casting integers to boolean (for example, 0::bool) is no longer allowed, use '0'::bool instead. This advice would probably only cause more confusion, because we are now moving into the direction that character strings are no

[HACKERS] Boolean casting in 7.3 - changed?

2002-11-26 Thread Ian Barwick
A quick question: in 7.3 the following no longer works: template1= select 0::bool; ERROR: Cannot cast type integer to boolean The statement must be rewritten as this: template1= select '0'::bool; bool -- f (1 row) Is there a reason for this? I ask because the former

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-26 Thread Tom Lane
Ian Barwick [EMAIL PROTECTED] writes: in 7.3 the following no longer works: template1= select 0::bool; ERROR: Cannot cast type integer to boolean Note that both old and new versions reject select 0::int4::bool; I believe the behavioral change is a consequence of Rod Taylor's

Re: [HACKERS] Boolean casting in 7.3 - changed?

2002-11-26 Thread Ian Barwick
On Wednesday 27 November 2002 06:23, Tom Lane wrote: Ian Barwick [EMAIL PROTECTED] writes: in 7.3 the following no longer works: template1= select 0::bool; ERROR: Cannot cast type integer to boolean Note that both old and new versions reject select