pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Joseph Syjuco <joseph@asti.dost.gov.ph>
To: Josh Berkus <josh@agliodbs.com>
Cc: Achilleus Mantzios <achill@matrix.gatewaynet.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: arrays as pgsql function parameters
Date: Mon, 10 Jun 2002 09:51:18 -0400
Message-ID: <3D04AED6.338B45E0@asti.dost.gov.ph> (raw)
References: <web-1502497@davinci.ethosmedia.com>

Josh Berkus wrote:
> 
> Joseph,
> 
> > actually i already have and basically the function statments start as
> >  create function test(_int4) returns integer
> > when i tried to execute the function
> >  select test('{1,2,3,4}');
> > it didnt spew out errors but it didnt output results either
> 
> How about posting a full function definition?
> 
> We're not telepathic.
> 
> -Josh

here is the sample function that i got from the internet.
hope you can send me a sample function

create function foo(_int4) returns int2 as'
    declare
    a _int4 alias for $1;
    i int:=1;
    begin
    while a[i] loop
    i:=i+1;
    end loop;
    return i-1;
    end;
    ' language 'plpgsql';



view thread (6+ messages)

Message-ID: <3D04AED6.338B45E0@asti.dost.gov.ph>
Permalink:  ../3D04AED6.338B45E0@asti.dost.gov.ph/
Also on:    postgresql.org/message-id/3D04AED6.338B45E0@asti.dost.gov.ph

 · 

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-sql@postgresql.org
  Cc: joseph@asti.dost.gov.ph, josh@agliodbs.com, achill@matrix.gatewaynet.com
  Subject: Re: arrays as pgsql function parameters
  In-Reply-To: <3D04AED6.338B45E0@asti.dost.gov.ph>

* 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