Subject RES: [Firebird-Java] Re: What is this? Help
Author Francisco Antonio Vieira Souza
> Thank you for answering, but I noticed that if I do the query with
> just ONE field that doesnt happen. What could that be?

That field type is known by driver, but some other is not.

> The definition of CLIENTES is below:

Please give me also defintion of your domains. Driver tests do not use
domains, maybe this is somehow related to this issue.

Here are my domains:
CREATE DOMAIN D_CNPJ AS VARCHAR(18) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_STATUS AS SMALLINT [0:1];
CREATE DOMAIN D_BAIRRO AS VARCHAR(30) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_CEP AS VARCHAR(10) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_CIDADE AS VARCHAR(35) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_COMPL_ENDERECO AS VARCHAR(30) CHARACTER SET ISO8859_1
COLLATE ISO8859_1;
CREATE DOMAIN D_CPF AS VARCHAR(18) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_DATA AS DATE;
CREATE DOMAIN D_EMAIL AS VARCHAR(40) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_ENDERECO AS VARCHAR(50) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_HP AS VARCHAR(30) CHARACTER SET ISO8859_1 COLLATE ISO8859_1;
CREATE DOMAIN D_IE AS VARCHAR(18) CHARACTER SET ISO8859_1 COLLATE ISO8859_1;
CREATE DOMAIN D_MENSAGEM AS BLOB SUB_TYPE 1 SEGMENT SIZE 80 CHARACTER SET
ISO8859_1;
CREATE DOMAIN D_NOME AS VARCHAR(50) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_TEL AS VARCHAR(18) CHARACTER SET ISO8859_1 COLLATE
ISO8859_1;
CREATE DOMAIN D_UF AS CHAR(2) CHARACTER SET ISO8859_1 COLLATE ISO8859_1;
CREATE DOMAIN D_MOEDA AS NUMERIC(16,2) CHECK( VALUE
BETWEEN -99999999999999.99 AND +99999999999999.99 );
CREATE DOMAIN D_NOTAFISCAL INTEGER(10);

Could you tell me if I am using the wrong version of Jaybird? I downloaded
this file FirebirdSQL-1.5.0Beta3JDK_1.4.zip and put the firebirdsql-full.jar
in my CLASSPATH (C:\j2sdk1.4.1_06\jre\lib\ext\firebirdsql-full.jar).

I have Firebird 1.5 running in Windows XP.

As Eugeney Putilin suggested I tried this way now (but with the same error):
String sql = "SELECT "+
"cli.IE, "+
"cli.NOME, "+
"cli.ENDERECO, "+
"cli.BAIRRO, "+
"cli.CIDADE, "+
"cli.UF, "+
"cli.CEP, "+
"cli.COMPLEMENTO, "+
"cli.TELEFONE, "+
"cli.FAX, "+
"cli.HOME_PAGE, "+
"cli.EMAIL, "+
"cli.ZONA, "+
"cli.VENDEDOR, "+
"cli.NOME_CONTATO, "+
"cli.DATA_CADASTRO, "+
"cli.STATUS "+
"FROM CLIENTES cli WHERE CNPJ=?";
java.sql.PreparedStatement ps = c.prepareStatement(sql);
ps.setString(1,cnpj);
ResultSet rs = ps.executeQuery();

I really appreciate your help, thanks.

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.688 / Virus Database: 449 - Release Date: 18/05/2004