OracleDataAdapter.Fill() requires cursor

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for Oracle
Post Reply
pocketscholar
Posts: 2
Joined: Mon 23 Mar 2015 21:21

OracleDataAdapter.Fill() requires cursor

Post by pocketscholar » Mon 23 Mar 2015 21:25

I have the latest version of dotConnect for Oracle. When I try to call the OracleDataAdapter.Fill() it doesn't give me the option of not including a Cursor. I don't want to use a cursor. What am I missing?

Code: Select all

Devart.Data.Oracle.OracleConnection orcConn = new Devart.Data.Oracle.OracleConnection(((SemApplication)tabApp).OMSConnectionString)
          Devart.Data.Oracle.OracleDataAdapter da = new Devart.Data.Oracle.OracleDataAdapter();
          da.SelectCommand = new Devart.Data.Oracle.OracleCommand();
          da.SelectCommand.Connection = orcConn;
          da.SelectCommand.CommandText = sql;
          orcConn.Open();
          da.Fill(dt);

Pinturiccio
Devart Team
Posts: 2141
Joined: Wed 02 Nov 2011 09:44

Re: OracleDataAdapter.Fill() requires cursor

Post by Pinturiccio » Tue 24 Mar 2015 15:48

The Fill method of OracleDataAdapter class has overloads that accept a parameter of an OracleCursor type. However, your sample uses an overload that does not accept OracleCursor. For more information, please refer to http://www.devart.com/dotconnect/oracle ... ~Fill.html
pocketscholar wrote:When I try to call the OracleDataAdapter.Fill() it doesn't give me the option of not including a Cursor. I don't want to use a cursor. What am I missing?
Please specify where you use a Cursor in your code.

pocketscholar
Posts: 2
Joined: Mon 23 Mar 2015 21:21

Re: OracleDataAdapter.Fill() requires cursor

Post by pocketscholar » Wed 25 Mar 2015 21:16

I was missing the Devart.Data reference. All I had was the Devart.Data.Oracle one. When I added Devart.Data my code was okay. I didn't want to use a cursor.

Post Reply