In case of Oracle and probably some other RDBMS+DataProvider, yes you are right.In practice, in Oracle, the Drive must recognize a StoredProcedure which will return a RefCurson in a output parameter and then do what is needed to return a IDataReader as expected.
2009/2/9 Ayende Rahien <[email protected]> > Hm,If I understand you correctly, we are talking about making the drive > responsible for returning the IDataReader from a query. > In Oracle's case, it will be a data reader on top of ref cursor, right? > > > On Mon, Feb 9, 2009 at 5:18 PM, Fabio Maulo <[email protected]> wrote: > >> H3 has a feature named "callable" used for certain Dialects as for example >> Oracle.In their implementation, each time a IDataReader is needed, they >> are asking for "callable" to choose which ResultSet getter is needed. >> To be clear... >> Suppose you have a StoredProcedure that are returning a ResultSet, the >> custom query are: >> - MsSQL : exec selectAllEmployments >> - MySQL : call selectAllEmployments() >> - ORACLE : call selectAllEmployments() >> >> For all, BUT ORACLE, you can use IDbCommand.ExecuteReader. >> ORACLE DataProviders has a "special behavior" (REF_CURSOR stuff). >> >> I tried to configure my mind to solve the problem in the same way H3 >> do but... I can't (too much "if" in too much places). >> >> The real underling problem is the DataProvider that, in term of NH mean >> the Drive. >> In my mind the Drive is the responsible to recognize a "callable" query >> and is the responsible to return a valid IDataReader implementation. >> >> If there is not opposition I will go ahead with this deviation from H3 >> implementation. >> >> -- >> Fabio Maulo >> > > -- Fabio Maulo
