| From: | KÖPFERL Robert <robert(dot)koepferl(at)sonorys(dot)at> |
|---|---|
| To: | pgsql-sql(at)postgresql(dot)org |
| Subject: | Re: query configuration for validate empty quote to zero |
| Date: | 2005-01-18 16:17:49 |
| Message-ID: | ED4E30DD9C43D5118DFB00508BBBA76EB16566@neptun.sonorys.at |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-sql |
Did you try to explicitly give the type for the literal?
e.g. ''::varchar
-----Original Message-----
From: Yudie [mailto:yudie(at)axiontech(dot)com]
Sent: Montag, 17. Jänner 2005 19:44
To: pgsql-sql(at)postgresql(dot)org
Subject: [SQL] query configuration for validate empty quote to zero
We just changed the postgresql server and got some problem with sql command
in our old server we can exexute this query:
SELECT * FROM product WHERE prdtnumber = ''
field prdtnumber data type is integer and the empty quote somehow can be
assumed into 0 (zero)
Now, if I use the same query it return an error:
invalid input syntax for integer: ""
Anyone know what's the problem??
Thanks
Yudie
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Keith Worthington | 2005-01-18 18:46:23 | Re: Returning a bool on DELETE in a proc. |
| Previous Message | KÖPFERL Robert | 2005-01-18 16:04:58 | Returning a bool on DELETE in a proc. |