stored procedure / Function - Mailing list pgsql-general

From Alain Roger
Subject stored procedure / Function
Date
Msg-id 75645bbb0611061123h61d3a6d6n8e0be7ca151a662c@mail.gmail.com
Whole thread Raw
Responses Re: stored procedure / Function  (Alban Hertroys <alban@magproductions.nl>)
List pgsql-general
Hi,

How to retrieve the IN parameter of a function for later use ?

i tried this :

CREATE OR REPLACE FUNCTION "public"."SP_U_001" ("TypeOfArticle" varchar) RETURNS SETOF "public"."active_articles" AS
$body$
DECLARE
  TypeArt VARCHAR := TypeOfArticle;
    rec RECORD;
    res active_articles;
/**************************************/
BEGIN

  SELECT articletypes.articletype_id INTO tpart FROM articletypes   
    WHERE articletypes.articletype_type = TypeArt;
....

but it seems that      TypeArt VARCHAR := TypeOfArticle;     does not work....

Can you help me ?
thx.
AL.

pgsql-general by date:

Previous
From: "Andrus"
Date:
Subject: How to force strong passwords
Next
From: Paul Ramsey
Date:
Subject: Re: PostGIS Binary RPM for Red Hat Linux