Thread: Postgres functions and Stored Procedures?

Postgres functions and Stored Procedures?

From
Kim Markle
Date:
I am new to Postgres and have researched the mail archives but I have
not found the answer for this (only questions).  I am very familiar with
using MS SQL 6.5 and have written tons of SP's.  The example below is
how one could write a SP for MS SQL which returns a record set.  My
question is how do I do this with Postgres functions?

create procedure ListAIS
as
select aisname as "AIS Name", aisdescription as "Description",
       username as "User Name", password as "Password" from ais_list
GO

GRANT  EXECUTE  ON dbo.EPRS_ListAIS  TO USER
GO

Thanks,

Kim Markle
Tivoli Kennels