Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
Thread How does EDBDataCursor works?
Wed, May 18 2011 4:31 AMPermanent Link

Jan

Hi!

I'm beginning to test the ADO.NET ElevateDB driver an i have a question:
Does the EDBDataCursor really works as a cursor like TDBISAMTable?

Lets say the CommandText is "SELECT * FROM MyTable" and i want to navigate via Locate and ReadCurrent. What is the (inner) ResultSet? Is it the complete table content or is it only one row?
Reloads a call of Refresh() the complete table content (SELECT *) or the current row only?

Regards an thanks,
Jan
Wed, May 18 2011 5:49 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Jan,

<< Does the EDBDataCursor really works as a cursor like TDBISAMTable? >>

Yes, in fact you can just set the CommandText to the table name, and then
set the CommandType to:

System.Data.CommandType.TableDirect

and you'll be able to just open a table directly.

<< Lets say the CommandText is "SELECT * FROM MyTable" and i want to
navigate via Locate and ReadCurrent. What is the (inner) ResultSet? Is it
the complete table content or is it only one row? >>

Any EDBCommand cursor, result set or direct table, always only has one row
loaded at a time.  However, if you hook any EDBDataCursor or EDBDataReader
up to any controls or objects that try to read the entire data set via Read
or ReadNext, then the entire dataset will be navigated.

<< Reloads a call of Refresh() the complete table content (SELECT *) or the
current row only? >>

Refresh doesn't actually reload the current row - it simply refreshes the
cursor.  If you want to get a new version of the current row, you'll need to
call ReadCurrent after calling Refresh.

--
Tim Young
Elevate Software
www.elevatesoft.com
Image