Click here to Skip to main content
15,887,365 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am trying to pass ref cursor as an input paramter to postgresql stored procedure.

I want to make this ref cursor input paramter as a generic one, so that I can pass any ref cursor as an input parameter for different databases like oracle, sql or postgresql stored procedures.

What I have tried:

able to write for oracle but unable to write for postgresql
Posted
Updated 2-Mar-21 4:02am
v2

1 solution

Well... I'm not sure what "generic cursor parameter" means, but...
I'd suggest to read this: Fetching result in Npgsql with refcursor. · Issue #1777 · npgsql/npgsql · GitHub[^]

Quote:
Long story short, your function shouldn't be returning a refcursor - simply return a table as described in the docs[^].
 
Share this answer
 
Comments
nsvrao 2-Mar-21 10:03am    
Thanks for your response.

I am trying to pass ref cursor as an input paramter to postgresql stored procedure.

I want to make this ref cursor input paramter as a generic one, so that I can pass any ref cursor as an input parameter for different databases like oracle, sql or postgresql stored procedures.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900