agora inbox for pljava-dev@postgresql.org  
help / color / mirror / Atom feed
Subject: [Pljava-dev] how to return complex type?
Date: Mon, 21 May 2007 18:48:46 +0200
Message-ID: <JIEHDA$C07DC140B2DDE054F6BFA8C48E80F36D@libero.it> (raw)

Hi to everyone
 I have to return a number and a word from a java function like a row, so I create a new type

CREATE TYPE test AS
   (number int4,
    word varchar);
ALTER TYPE test OWNER TO gbedidi;

and I tried to use it from the function.
The function looks like as follow

public static boolean test2(Integer num, String par1, ResultSet receiver) throws SQLException {
		Utilities.LogOutput(Integer.toString(num)+" "+par, debug);
		receiver.updateInt(1, num);
		receiver.updateString(2, par);
		return true;
	}

but it didn't work so I tried also to map the complex type into a java class but it didn't work anyway...
Anyone can help me?
Regards




------------------------------------------------------
Passa a Infostrada. ADSL e Telefono senza limiti e senza canone Telecom
http://click.libero.it/infostrada






Message-ID: <JIEHDA$C07DC140B2DDE054F6BFA8C48E80F36D@libero.it>
Permalink:  ../JIEHDA$C07DC140B2DDE054F6BFA8C48E80F36D@libero.it/
Also on:    postgresql.org/message-id/JIEHDA$C07DC140B2DDE054F6BFA8C48E80F36D@libero.it

reply

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 using the --to and --cc options:
  reply via email

  To: pljava-dev@postgresql.org
  Subject: Re: [Pljava-dev] how to return complex type?
  In-Reply-To: <JIEHDA$C07DC140B2DDE054F6BFA8C48E80F36D@libero.it>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox