pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: NosyMan <nosyman@gmail.com>
To: pgsql-jdbc@postgresql.org
Subject: jdbc and ARRAYs
Date: Fri, 2 Dec 2005 11:42:38 +0200
Message-ID: <200512021142.38982.nosyman@gmail.com> (raw)

Hi everyone,

I have some problems trying to use a preparedStatement with an array 
parameter. The problem is I don't know how to do it :-(

CREATE OR REPLACE FUNCTION MyFunction( id INTEGER, anArray 
VARCHAR[] )..........................


pstat = conn.prepareStatement("SELECT * FROM MyFunction(?,?)");
pstat.setInt(1, 30);
pstat.setArray(2, ??????????);

Can you tell me how can I construct the array for parameter number 2?

Thanks,
NosyMan




view thread (11+ messages)  latest in thread

Message-ID: <200512021142.38982.nosyman@gmail.com>
Permalink:  ../200512021142.38982.nosyman@gmail.com/
Also on:    postgresql.org/message-id/200512021142.38982.nosyman@gmail.com

 · 

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 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: nosyman@gmail.com
  Subject: Re: jdbc and ARRAYs
  In-Reply-To: <200512021142.38982.nosyman@gmail.com>
  References: <200512021142.38982.nosyman@gmail.com>

* 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