我的存储过程如下
create or replace PROCEDURE "GetAllClientNames" ( "ID" IN NUMBER,"SAL" IN NUMBER,"EMP_CURSOR" OUT SYS_REFCURSOR) IS BEGIN OPEN EMP_CURSOR FOR SELECT FIRSTNAME FROM CLIENTS; END;
但是在更新实体并执行函数导入时,导入的函数中未检测到SYS_REFCURSOR OUT参数以检索结果集.
请帮我解决这个问题.没有OUT参数我无法访问存储过程检索的结果集
ODP.NET 11g Release 2 (11.2.0.3.0),and higher,enables applications
to run stored procedures with REF CURSOR parameters without using
explicit binding for these parameters in the .NET code.For a read-only result set,such as a REF CURSOR using
OracleDataReader,REF CURSOR schema information is retrieved
automatically.For some scenarios,such as when updateable REF CURSORs or Entity
Framework is used,developers need to define the REF CURSOR schema
information so that the application can bind the implicit REF CURSOR.
Entity Framework applications use implicit REF CURSOR binding to
instantiate complex types from REF CURSOR data. Applications must
specify REF CURSOR bind and Metadata information in the app.config,
web.config,or machine.config .NET configuration file.The attributes supplied in the .NET configuration file are also used
when the application requests for schema information from the
OracleDataReader object that represents a REF CURSOR. This means that
for REF CURSORs that are created using a SELECT from a single table,
the application can update that table through the use of
OracleDataAdapter and OracleCommandBuilder.When using the Entity Framework,function imports can return an
implicitly-bound REF CURSOR. The REF CURSOR can be returned as a
collection of complex types or entity types. To return a complex type
collection,the .NET configuration file needs to define the REF CURSOR
bind and Metadata information. To return an entity type collection,
only the bind information needs to be defined in the .NET
configuration file.
查找完整信息here