So, i have a function (that i can't change), that returns table of objects, and i need to get them in c# code.
create or replace FUNCTION choose_name( )
RETURN TBL_names IS
result TBL_names:=TBL_names();
/*
CREATE OR REPLACE TYPE OBJ_names as object (
"Param1" varchar2(555),
"Param2" NUMBER
)
CREATE OR REPLACE TYPE TBL_names is table of OBJ_names
*/
And here is a c# code for this:
command.CommandType = CommandType.StoredProcedure;
command.CommandText = "choose_name";
command.Parameters.Add("TBL_names", OracleDbType.RefCursor).Direction = ParameterDirection.ReturnValue;
But i 'm getting an error - wrong types of arguments. I understand that it is a table, not a ref cursor. How am I suppose to accomplish that?
"Param1"(in double-quotes) then everyone who ever refers to it, ever, has to use"Param1", quotes and all.