X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 9E9D5D9201 for ; Tue, 27 Sep 2005 04:06:47 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 48001-09 for ; Tue, 27 Sep 2005 07:06:43 +0000 (GMT) Received: from obelix.askesis.nl (laudanum.demon.nl [82.161.125.16]) by svr1.postgresql.org (Postfix) with ESMTP id 04B46D8F38 for ; Tue, 27 Sep 2005 04:06:39 -0300 (ADT) Received: obelix.askesis.nl 172.31.0.1 from 172.31.1.8 172.31.1.8 via HTTP with MS-WebStorage 6.0.6249 Received: from Panoramix by obelix.askesis.nl; 27 Sep 2005 09:06:35 +0200 Subject: Exception storing ipaddress with JBoss after upgrade to 8.0-312.jdbc3 From: Joost Kraaijeveld To: "pgsql-jdbc@postgresql.org" Content-Type: text/plain Content-Transfer-Encoding: 7bit Date: Tue, 27 Sep 2005 09:06:35 +0200 Message-Id: <1127804795.4050.40.camel@Panoramix> Mime-Version: 1.0 X-Mailer: Evolution 2.0.4 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.33 required=5 tests=[AWL=-0.190, FORGED_RCVD_HELO=0.05, TO_ADDRESS_EQ_REAL=0.47] X-Spam-Level: X-Archive-Number: 200509/111 X-Sequence-Number: 13896 Hi, I am trying to store an ipaddress in a PostgreSQL column of a INET type. This used to work with pg74.216.jdbc3 but after an upgrade to postgresql-8.0-312.jdbc3 I get an exception: ERROR: column "ipaddress" is of type inet but expression is of type character varying. The PostgreSQL log shows: LOG: statement: INSERT INTO accesspoint (objectId, ipAddress, locationName, macAddress, manufacturer, serialNumber, supplier, typeName, address) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9) 2005-09-27 08:57:48 [12459] ERROR: column "ipaddress" is of type inet but expression is of type character varying HINT: You will need to rewrite or cast the expression. De CMP field is defined as @jboss.jdbc-type VARCHAR and @jboss.sql-type INET Is this a known problem? If so, is there a known sollution (and are you willing to share that sollution ;-))? The suggestion about the rewrite/cast hint is not possible because this is a CMP bean and JBoss takes care of writing that . -- Groeten, Joost Kraaijeveld Askesis B.V. Molukkenstraat 14 6524NB Nijmegen tel: 024-3888063 / 06-51855277 fax: 024-3608416 e-mail: J.Kraaijeveld@Askesis.nl web: www.askesis.nl