pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Joe Conway <mail@joeconway.com>
To: Alexaki Sofia <alexaki@ics.forth.gr>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: arrays as input parameter for c functions
Date: Fri, 12 Jul 2002 08:57:31 -0700
Message-ID: <3D2EFC6B.1060900@joeconway.com> (raw)
References: <Pine.GSO.4.33.0207121726390.28885-100000@ourania.ics.forth.gr>

Alexaki Sofia wrote:
> thank you for your answer.
> 
> Could you tell me how such a function is it called?
> 
> Let's say that the function is test(text[])
> how can I call this function from a sql command, i.e., what
> will be teh value of the input parameters?
> 
> select test(?????????)
> 

See contrib/dblink in CVS HEAD, specifically dblink_build_sql_insert(), 
dblink_build_sql_delete(), or dblink_build_sql_update(). These functions 
accept text arrays (and int2vector) as input. In the README there are 
usage examples.

HTH,

Joe






view thread (4+ messages)

Message-ID: <3D2EFC6B.1060900@joeconway.com>
Permalink:  ../3D2EFC6B.1060900@joeconway.com/
Also on:    postgresql.org/message-id/3D2EFC6B.1060900@joeconway.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 using the --to and --cc options:
  reply via email

  To: pgsql-interfaces@postgresql.org
  Cc: mail@joeconway.com, alexaki@ics.forth.gr, tgl@sss.pgh.pa.us
  Subject: Re: arrays as input parameter for c functions
  In-Reply-To: <3D2EFC6B.1060900@joeconway.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