NetBase SQL Shadowing Handbook

Installation NetBase SQL
____________________________________________________________
2-12 QUEST Software, Inc. ver A0195
Multi-Directional SQL Shadowing
The most complex use of SQL shadowing is when you want to export updates from all machines
in a network to all other machines in the network. To reduce the chances of synchronization
problems, you should consider some form of partitioning. The idea behind partitioning is that
master copies of different sections of a DBE are kept on different systems. This may be
accomplished using user exits or by using TABLE entries in NBDIR.
In the example using user exits below, let's say we have PRODDBE on SYSA, SYSB and SYSC,
and we want to have each node updated from the other two nodes.
On SYSA, we enter:
D> SQLOUT PRODDBE.DATA.PROD,SYSB;HOME=1;USEREXIT
D> SQLOUT PRODDBE.DATA.PROD,SYSC;HOME=1;USEREXIT
D> SQLIN PRODDBE.DATA.PROD,SYSB;USEREXIT
D> SQLIN PRODDBE.DATA.PROD,SYSC;USEREXIT
On SYSB we enter:
D> SQLOUT PRODDBE.DATA.PROD,SYSA;HOME=2;USEREXIT
D> SQLOUT PRODDBE.DATA.PROD,SYSC;HOME=2;USEREXIT
D> SQLIN PRODDBE.DATA.PROD,SYSA;USEREXIT
D> SQLIN PRODDBE.DATA.PROD,SYSC;USEREXIT
On SYSC we enter:
D> SQLOUT PRODDBE.DATA.PROD,SYSA;HOME=3;USEREXIT
D> SQLOUT PRODDBE.DATA.PROD,SYSB;HOME=3;USEREXIT
D> SQLIN PRODDBE.DATA.PROD,SYSA;USEREXIT
D> SQLIN PRODDBE.DATA.PROD,SYSB;USEREXIT
See the next page for an illustration of this example.