Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

clear ado dataset

Status
Not open for further replies.

kumori25

Programmer
May 22, 2003
11
SG
hi,
i'm using adoqery to extract database data (using adoquery)for display in a dbgrid. this grid has to be refreshed each time new documents are added.
the problem that i have is that i allow users to add multiple documents (say 5), which are saved in a a cached dataset, and the 5 documents are updated to the database at one shot with updatebatch command. But i can't seem to clear the dataset with the commitupdate command. so my data in the datagrid shows not just the 5 recently added documents does anyone have any idea?
 
I would refire the query after the update. Unless you are using a table the dataset doesn't catch when the data on the server is updated

Steven van Els
SAvanEls@cq-link.sr
 
hi
thanks for your help. i tried to do it but there was still an error.
also, when i fire the update command, the data cannot be inserted into the database at all, there is always an error
 
Just a wild thought.
If your datasource has a time added field or if you add a time added field (set a field and add the time stamp)then you can filter your query based on excluding items before a certain time . This also means you can include items after a certain time.
Hope this helps.
Yomi.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top