Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

BUG #2456: How to write user defined functions in Postgress sql



The following bug has been logged online:

Bug reference:      2456
Logged by:          Vivekananda
Email address:      r(dot)vivekanandaswamy(at)yahoo(dot)co(dot)in
PostgreSQL version: 8.1
Operating system:   Windows-2000
Description:        How to write user defined functions in Postgress sql
Details: 

Hai,
I have good knowledge in Oracle-Pl/sql.But,now my client wants to use
PGSQL.Now i am sending function as below.

create or replace function fun_emp(eno integer) returns varchar
as 
v_name varchar;
begin
select ename into v_name from emp where empno=eno;
return v_name;
end;
/
SQL>Select fun_emp(7788) from dual;

SQL>Fun_emp(7788)
-----------------
SMITH

It's work on Oracle-Pl/sql.
Now how can i implemnt this function in PGSQL?



Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group