Bidirectional database synchronization

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
User avatar
emmbec
Forum Contributor
Posts: 112
Joined: Thu Sep 21, 2006 12:19 pm
Location: Queretaro, Mexico

Bidirectional database synchronization

Post by emmbec »

Hi everyone, has anyone ever tried to synchronize two databases in a bidirectional way? I have a problem right now, where I have two databases in two different servers in different networks (and they cannot see each other and they never will...), this databases hold employee information, but the thing is that people are in two different buildings, and for some company policy issues there cannot be any link between the two building's networks, and at last but not least, there is no internet connection in the buildings, pure local network.

We have a system to hold employee information that uses a MySQL database for this in each network. Now here is the thing:

1.- The Human Resources Department is in one building.
2.- Employee information is in two separate buildings, but some people can go from one building to another, and they can be changing their personal information in any of the two buildings.
3.- We have managers who are in both buildings, and they would like to see the employee information no matter in which building they are on.

- How could I keep the two databases synchronized correctly?
- Is there a FREE tool out there to accomplish this (My boss doesn't want to spend money on any tool :x )?
- Any PHP script to do this?

Don't worry about user names and passwords, that issue has been solved using active directory in each network (Yes, we have two different usernames and passwords for both buildings).

Any ideas on how to do this??

Many thanks!
User avatar
Jade
Forum Regular
Posts: 908
Joined: Sun Dec 29, 2002 5:40 pm
Location: VA

Re: Bidirectional database synchronization

Post by Jade »

Ugh, that sounds like a terrible setup, lol. My suggestion would be to get a third server that both of the buildings send their updates to. Then you could have each server periodically check to the server for updates.

Otherwise, if you try to have both of them sending data back and forth to each other all the time I think you'll have problems with duplicate records and missing records. A go between that's always up to date would be the best idea in my opinion.
Post Reply