Page 1 of 1
About QueryrecCount&FetchAll.
Posted: Wed 04 Aug 2010 06:56
by capelin
For Unidac3.00.0.10,I have problem:
For Mysql,
FetchAll:=False,QueryrecCount:=False,The RecordCount is 25.
FetchAll:=False,QueryrecCount:=True,The RecordCount is all record.FetchAll Funtion is invalid.
But I want Showing real RecordCount on FetchAll:=False.Why?
Posted: Wed 04 Aug 2010 10:15
by Dimon
If QueryRecCount = True, and FetchAll = False, TCustomMyDataSet performs additional query to get the record count for this SELECT, so the RecordCount property reflects the number of records of the whole result set that is the count of records that will be fetched.
If QueryRecCount = False, RecordCount reflects the number of fetched records. To fetch next batch of records use the Next method.
Posted: Wed 04 Aug 2010 15:11
by capelin
I need to FetchAll = False effect, and hope the RecordCount return to the results of this query. How?
Posted: Thu 05 Aug 2010 08:37
by Dimon
If FetchAll = False, and QueryRecCount = False, RecordCount reflects the number of fetched records. RecordCount will increase after every next fetching of batch of records.