I have a project that must have centralization of databases that will have access to the web on a PHP script. I can merge MSSQL and MySQL databases if and only if they were both:
1.) On a same server or
2.) Of the same server type
The problem is what if they were on 2 distinct types of server. Like what the title's scenario is.

May be I am at the wrong section but because this relates with PHP, I posted here.

Recommended Answers

All 3 Replies

Hello,

The databases do not have to be on the same server or the same type of server they must simply have a location that both servers can somehow read and write files to. I do this all of the time working database conversions for companies. Normally I use Perl (or VB) scripts to export the data from one database and import the data to the other. The file delimiters can be based on any unique charactor that is not normally used in your data but CSV files normally work just fine.
First you need to decide what the final server hosting the web site is going to be running and then set up a location for the two servers to write to (Linux Samba, Windows mapped drive, sftp, pscp or scp). If you are only displaying data on the web site and not updating it there then I usually delete the whole table and recreate it prior to importing the data so there is no residue form the previous data. And if you script the exports and imports and you can then schedule them to run from cron jobs or task scheduler several times a day if needed. It also is normally faster to drop a table and import all rows than to test for differences and update rows if needed.
I also suggest that if you have enough room store the export files for a few days or more after you import them. Sometimes you have to prove that you got garbage and that is why you imported garbage.

Project scenario... whether at the office or anywhere in the world... any transactions in particular that they were using... they were still be able to see what was in their business. For example, I want to transact on my office but I am at somewhere else in the world. So any where I am, I feel like no such problem like I was in the office even when I am not. The project scenario is somewhat close or exact as the cloud computing system. But I dont want to destroy their existing offline system, I just want to innovate with the access over the web

I changed my plan of fetching data. I will get their data on their offline database, then store online transactions also on the intranet database. The problem mainly as what I still worrying about is how will I get the intranet's database's hosting address and port?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.