Menu
  • HOME
  • TAGS

plpgsql - How to return out parameter and ref cursor from stored procedure?

postgresql,stored-procedures,plpgsql,out-parameters,ref-cursor

When you use one OUT variable, then result type have to be same type as OUT variable. When you want to return more than one values, you have to use more OUT variables and result type should be RECORD or RETURNING part can be ignored. Modern PostgreSQL doesn't allow what...

Populating C# datatable with refcursor values from an Oracle Stored Procedure

c#,sql,oracle,stored-procedures,ref-cursor

You are retrieving only one column GRANTED_ROLE in the cursor query: OPEN UserRole FOR select GRANTED_ROLE from DBA_USERS DU, ....... however you are trying to fetch an UserRole column from the cursor. if (dr["UserRole"].ToString().ToUp......... There is not any column named UserRole there, you can only fetch GRANTED_ROLE....

Error printing REFCURSOR variable as OUT parameter in procedure in Oracle 11g

oracle,variables,oracle11g,ref-cursor

var r ref cursor; The above is syntactically incorrect. It should be - var r refcursor There is not space between ref cursor, it is one word, refcursor. For example, SQL> create table t as select * from emp; Table created. SQL> var r refcursor SQL> SQL> begin 2...