Improve company productivity with a Business Account.Sign Up

x
?
Solved

Monitoring a database for changes with ADO

Posted on 2002-05-13
2
Medium Priority
?
319 Views
Last Modified: 2006-11-17
I am trying to monitor a database for additions, changes or deletions.  The changes come from a third party app that I do not have source for.  I know the app uses ADO because it installs the latest version of ADO when it is installed.

I need real-time performance from the database so I've decided to cache all the data in memory while my application is running.

However, to keep the cache up-to-date with the database, I need some way of being notified when a change takes place so I can update the cache.

Will ADO provide the kind of events I'm looking for?
0
Comment
Question by:jlalande
2 Comments
 
LVL 22

Accepted Solution

by:
DrSQL earned 800 total points
ID: 7009571
jlalande,
   If I understand your question correctly, I think you're looking the wrong place.  It is the database that knows when it has been changed, not ADO.  What DB engine are you using?  If it has the ability to create triggers, then it could populate a database structure or perhaps run a java applet that would tell your app whether there were changes.  ADO is just the objectification layer/interface.

   It might mean regularly polling a simple DB structure, but would still allow you to update your cache in a more timely fashion (and based upon actual activity rather than a time interval).

Good luck!
0
 

Author Comment

by:jlalande
ID: 7009606
DrSQL

Thanks for your comments.

The third party app uses either SQL Server or dBase depending on what the user selects at install time.  I think the default is dBase.

I considered the trigger approach but wasn't sure if my program could add triggers to another application's database.  I should do more research and experimentation.

I was intrigued by the ADO approach since two more third party apps we have to work with actually generate COM events when they update their databases...though there databases are in a proprietary format.

But if ADO won't do the trick, I'll follow your suggestion.

Thanks
John
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Creating a Cordova application which allow user to save to/load from his Dropbox account the application database.
Microsoft Jet database engine errors can crop up out of nowhere to disrupt the working of the Exchange server. Decoding why a particular error occurs goes a long way in determining the right solution for it.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

589 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question