Synchronising dbs from several servers

Ruslan Zasukhin sunshine at public.kherson.ua
Thu Oct 28 17:02:15 CDT 2004


On 10/28/04 11:43 AM, "Florian Bogeschdorfer" <fb at memedia.de> wrote:

Hi Florian,
 
> I need to synchronize adresses and payback cards between different outlets,
> each running it's own vServer and DB in my current application.
> 
> I thought about sending changes (change,new,delete) in the two important
> tables to an online Db/php,mySQL where each outlet can then download the
> changes. Do you see a better way?

First of all, you MUST to have some online center. Right?


> Since I made a single handler doing all record changes like
> 
> On VALchangerecord cursor,data
>   --change data here
>   ..
>   ..
>   ..
> End
> 
> I am now in trouble, because I would have to catch if the changes are in the
> 2 mentioned tables, something like:
> 
> On VALchangerecord cursor,data
>   --change data here
>   ..
>   ..
>   ..
>   If table of cursor is "Adress" or "card" then
>     --synchronize with internet
>   end if
> End
> 
> But I see no way to find out the table(s), that a cursor refers to. Is there
> a way?

No such way.

> Otherwise I would have to change every call to the changerecord sub...

This is hard task.

You can read about replication.
One server publish some tables, other servers subscribe to them.
Only publisher can write to that tables, rest read.

You can think about usage in these 2 tables the COLUMN 'datetime'.
And use its for synchronization.

-- 
Best regards,
Ruslan Zasukhin      [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com

To subscribe to the Valentina mail list go to:
http://lists.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------




More information about the Valentina mailing list