Re: [SQL] Postgres 8 - problem: invalid input syntax for integer

2005-02-28 Thread Richard Huxton
mauro wrote: What number does '' represent? 'No response' value... Would've been better to have a genuine response_provided flag, but then you obviously know that. Who is providing an empty string where you've asked for a number, and why not trap this error (or store a NULL)? You are certainly r

Re: [SQL] Postgres 8 - problem: invalid input syntax for integer

2005-02-28 Thread mauro
> What number does '' represent? 'No response' value... > Does that mean a string of '/2' should equal your number divided by two? right, but it is never required. > If not, why not? because I use it to GROUP BY values. > Who is providing an empty string where you've asked for a number, and > why

Re: [SQL] Postgres 8 - problem: invalid input syntax for integer

2005-02-24 Thread Richard Huxton
mauro wrote: Hi, In previous version di Postgres (7.2) I used this table: CREATE TABLE tablename (id serial, field int1, field2 text); Now this query work: UPDATE tablename SET field1=''; (NOTE: implicit conversion to 0) UPDATE tablename SET field2=''; (this cause of simple code-generation query -