From: Edoardo Panfili <edoardo@aspix.it>
To: pgsql-jdbc@postgresql.org
Subject: error: operator does not exist: bigint = character varying
Date: Wed, 27 Jun 2007 23:12:41 +0200
Message-ID: <4682D2C9.1010406@aspix.it> (raw)
Hi,
I am updating from 8.2.4 to 8.3dev
the jdbc driver is postgresql-8.3dev-600.jdbc3.jar
Now my application raises this exception (all was ok with 8.2):
org.postgresql.util.PSQLException: ERROR: operator does not exist:
bigint = character varying
this is my code fragment
----------------------------------------------------------------------
PreparedStatement ps = connessione.prepareStatement("SELECT
strato.idplot, strato.idstrato, strato.nome, strato.copertura,
strato.altezza, strato.note FROM plot WHERE idplot=?");
ResultSet risultatoStrati;
ps.setString(1, rilievo.dato[Rilievo.ID]);
risultatoStrati = istruzioneStrati.executeQuery();
----------------------------------------------------------------------
The error is in the last istruction, it seems that I am doing somehing
not clean with types.
the type of idplot is
"idplot integer NOT NULL DEFAULT nextval('sequenza_plot'::regclass)"
I did a try with
ps.setInt(1, Integer.parseInt(rilievo.dato[Rilievo.ID]));
but nothing is changed.
Whath I am doing wrong?
If I exec "SELECT
strato.idplot,strato.idstrato,strato.nome,strato.copertura,strato.altezza,strato.note
FROM strato WHERE idplot=567" from pgadmin all goes well.
thank you
Edoardo
--
Jabber: edoardopa@talk.google.com
tel: 075 9142766
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: edoardo@aspix.it
Subject: Re: error: operator does not exist: bigint = character varying
In-Reply-To: <4682D2C9.1010406@aspix.it>
References: <4682D2C9.1010406@aspix.it>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox