🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.database
Article #204

ProcedureDataSet and resultSetToDataSet doesn't work

#204
From: Christa Schneider
Date: Fri, 23 Jun 2006 11:01
33 lines
1975 bytes
Hi,

I have a problem with ProcedureDataSet it doesn't work and I don't  know 
why?
I work with JBuilder 9 and Postgres 7.4 (Postgres 8.01)

Here is the Quellcode:

row.addColumn("ref", Variant.OBJECT, ParameterType.RETURN);
row.getColumn("ref").setSqlType(Types.OTHER);
row.addColumn("krit", Variant.STRING, ParameterType.IN);
row.setString("krit", "where value=15");

//Error!
db.setAutoCommit(false);
pr.setProcedure(new com.borland.dx.sql.dataset.ProcedureDescriptor(db, "{? = 
call func(?)}", row, true, Load.ALL));
pr.executeQuery();

When I called it with ProcedureProvider it works fine, but I get a 
NullPointerException by db.resultSetToDataSet

ProcedureProvider p = new ProcedureProvider();
p.callProcedure(db, "{:ref = call func(:krit)}", row);
ResultSet rs1 = (ResultSet) row.getObject("ref");

//Error! NullPointerException
StorageDataSet pd=new StorageDataSet();
db.resultSetToDataSet(ds,rs1); //or pd = db.resultSetToDataSet(rs1);

Can anybody help me?
Thanks
Christa Schneider 
Technical Details
Message-ID: <449bca0b$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx02.iad01.newshosting.com!newshosting.com!news-out.nuthinbutnews.com!sp6iad.superfeed.net!in1.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 1073da,de14a88c3d1af0e4,start
X-Google-Attributes: gid1073da,public
X-Google-Language: ENGLISH,ASCII-7-bit
Subject: ProcedureDataSet and resultSetToDataSet doesn't work
From: "Christa Schneider" <csk@ignicon.de>
Date: Fri, 23 Jun 2006 13:01:23 +0200
Message-ID: <449bca0b$1@newsgroups.borland.com>
Lines: 35
NNTP-Posting-Host: 85.181.127.72
Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx02.iad01.newshosting.com!newshosting.com!news-out.nuthinbutnews.com!sp6iad.superfeed.net!in1.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
Newsgroups: borland.public.jbuilder.database
X-Trace: newsgroups.borland.com 1151060491 85.181.127.72 (23 Jun 2006 04:01:31 -0700)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2869
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2869
X-RFC2646: Format=Flowed; Original