Windows NT / Oracle 8i / BCB5 / DOA 3.3.2

RecordCount is not up to date after deleting a record:
I have a OracleDataset based on a "normal" table or on a temporary table.
By example, it contains 8 records.
RecordCount is 8.
When I delete one record (ore more), record count stills says 8.

Via the debugger window, I've also noticed that the private member Records->RecordCount() contains the correct number...

Thanks for help...

------------------
St
I assume you have set CountAllRecords to True (in other words, you need to know the total number of records in the result set before they are actually fetched). In this case the RecordCount property does indeed not include inserted or deleted records. We'll try to fix this in the 3.4 release.

If CountAllRecords is False, the RecordCount property will reflect the number of records that are fetched. In this situation the inserted and deleted records are included as well. This may be a possible work around.

------------------
Marco Kalter
Allround Automations
Thanks Marco !

To always have RecordCount up to date,
this solution works fine:

- Set CountAllRecords to TRUE
- Open the DataSet.
- Set CountAllRecords to FALSE, assuming correct recordcount when adding/removing records.

- Don't forget to Set CountAllRecords to TRUE before each re-opening, then resetting it to FALSE just after.


------------------
St
© Allround Automations forums