Click here to Skip to main content
15,896,118 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Am having a msaccess db(used by others) and also a sql db(my db) too, whenever access database got row or data INSERTED, i want my db inserted with same row or data


ACTUALLY I NEED A TRIGGER KIND OF THING BUT IT WONT B POSSIBLE IN ACCESS


Note: am not having the control over that msaccess db.


Please help me with simple solutions if any??

thanks in advance
Posted
Updated 28-Mar-13 1:52am
v2
Comments
[no name] 28-Mar-13 7:59am    
Do you really think that screaming at people will help? The only way I know of that might work for this situation is to poll the access db for changes. But I would recommend that you do something else and only use one database.
ZurdoDev 28-Mar-13 8:01am    
Basically you need to poll at a regular interval. For example, INERT INTO SQLTable WHERE NOT EXISTS (SELECT * FROM accesstable). If you can't have any control of the access db you can't have it tell you when records are changing.
Maciej Los 30-Apr-13 17:29pm    
Not clear, please, be more specific and provide more details.

1 solution

A) You need to create logs

For creating log you may create a generic table with 3 information & Sync flag
- Table name
- Primary Key (record identified)
- Action (Insert / Update / Delete)
- Sync (Y/N) ~ default during insert as 'N'

You can use triggers for doing an insert for


B) You will need an stand alone application which is running all the time at specific interval read this logs and connects to your choice of DB using JDBC and replicates information. On replication, either deletes the record or marks Sync flag as "Y"
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900