Strange error

From: Felipe Schnack <felipes(at)ritterdosreis(dot)br>
To: pgsql-jdbc <pgsql-jdbc(at)postgresql(dot)org>
Subject: Strange error
Date: 2003-01-02 13:48:29
Message-ID: 1041515309.1282.5.camel@desenv1.ritterdosreis.br
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

I'm getting this very strange error. I'm setting the null to Types.NULL..

INSERT INTO PESSOAS (rg, cpf, nomepessoa, nascimento, sexo, email,
endereco,bairro, codcidade,codpessoa) VALUES (null, null, 'Arno João
Bosetti', null, 'M', null, 'Av. Prof. Oscar Pereira,1220 /908', 'Santo
Antonio',1,1)

java.sql.SQLException: ERROR: column "cpf" is of type bigint but
expression is of type text
You will need to rewrite or cast the expression

at org.postgresql.core.QueryExecutor.execute(QueryExecutor.java:126)
at
org.postgresql.jdbc1.AbstractJdbc1Connection.ExecSQL(AbstractJdbc1Connection.java:497)
at
org.postgresql.jdbc1.AbstractJdbc1Statement.execute(AbstractJdbc1Statement.java:320)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:48)
at
org.postgresql.jdbc1.AbstractJdbc1Statement.executeUpdate(AbstractJdbc1Statement.java:197)
at
com.w2.login.daemons.UniversusImport.importPessoas(UniversusImport.java:238)



--

Felipe Schnack
Analista de Sistemas
felipes(at)ritterdosreis(dot)br
Cel.: (51)91287530
Linux Counter #281893

Centro Universitário Ritter dos Reis
http://www.ritterdosreis.br
ritter(at)ritterdosreis(dot)br
Fone/Fax.: (51)32303341

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Felipe Schnack 2003-01-02 14:02:44 Re: Strange error
Previous Message Thorsten Meinl 2002-12-30 17:28:58 Re: batch example