Re: Pl/Pgsql function troubles: FOLLOW UP

From: Oliver Elphick <olly(at)lfix(dot)co(dot)uk>
To: Jeff Post <postjeff(at)uwm(dot)edu>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Pl/Pgsql function troubles: FOLLOW UP
Date: 2002-04-16 22:37:30
Message-ID: 1018996650.27903.66.camel@linda
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Tue, 2002-04-16 at 22:58, Jeff Post wrote:
> here is Code that I got working but I still have some problems with:
> (I am asking for help, so if you wish to skip to my question read the last
> sentance)
>
> CREATE or replace FUNCTION list_of_membership(integer,CHAR) RETURNS TEXT AS '
...
> FOR membership_rec IN EXECUTE sqlstr1 || $1 || sqlstr2 || $2 || sqlstr3
^^
quote_literal($2)

Think what the command would look like if you ran it directly. A
literal string must be quoted.

--
Oliver Elphick Oliver(dot)Elphick(at)lfix(dot)co(dot)uk
Isle of Wight http://www.lfix.co.uk/oliver
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839 932A 614D 4C34 3E1D 0C1C

"But seek ye first the kingdom of God, and his
righteousness; and all these things shall be added
unto you." Matthew 6:33

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Josh Berkus 2002-04-17 03:42:08 Re: cannot restore db
Previous Message Jeff Post 2002-04-16 21:58:14 Pl/Pgsql function troubles: FOLLOW UP