synchronizing data

Maurice

New Member
Hello overthere,

I have the folowing issue. We made a CRM-application with travel possibilities. Synchronising is now done by connecting the travel-notebook (with CRM-travel-DB) to the network (logging on to CRM-central-DB).

We want to add functionality so that we don't need the direct connection to the CRM-central-DB for synchronising anymore. We want to be able to synchronise the CRM-travel-DB with the CRM-central-DB based on exchanging files.

I have these questions:
- What the best procedure to synchronise based on file-exchange?
- What file format should we use (XML, CSV, ...) ?
- How to send these files (e-mail, ...) ?
- How to make the CRM-central-DB to see new synchronisation files?
- How to make the CRM-travel-DB to see new synchronisation files?
- How to handle synchronisation collisons ?

There should be somebody out there who already found solutions to make this possible?

Who can help me?
 
Synchronizing data is always a nice challenge :) This is a difficult subject that could fill by itself a full website ! (Have you tried any algorithm site around ?)




- What the best procedure to synchronise based on file-exchange?

There's no internal procedure with Progress for synchronization. You have to create everything by yourself (or so).

- What file format should we use (XML, CSV, ...) ?

Depends on what you want to do. I think XML is sometime slow for huge datas and CSV is not clean because CSV separator is the ";" character that might already be inside your datas. I would rather use TXT file with a pipe as separator.

- How to send these files (e-mail, ...) ?

How about a simple DOS/UNIX batch that would make the copy of the file from the local computer to the server computer ? But this of course imply that both DB are on the same network.


- How to make the CRM-central-DB to see new synchronisation files?

Use Cron (if Unix) or the Windows Scheduler (Nt/2k) that launch a simple Progress program watch if a new file is here :

FILE-INFO:FILE-NAME = "c:\your-file.txt".
IF FILE-INFO:FULL-PATHNAME = ? THEN
DO:
/* No new file */

END.
ELSE
DO:
RUN Synchro_procedure.
/* delete your file after synchro is done */
END.




- How to handle synchronisation collisons ?

That's the most difficult point in my opinion. It all depends on your application. The best way would be that each database has its own ID, and this ID would be inserted in each record of the DB, why not as a part of the primary key.

Good luck
 
Top