Synchronization of two or more data sources

Discussions about CSEntry
Forum rules
New release: CSPro 8.0
Post Reply
vgonzalez
Posts: 27
Joined: March 12th, 2020, 4:19 pm
Location: VENEZUELA

Synchronization of two or more data sources

Post by vgonzalez »

Greetings CSPro team

I would like to ask you about the optimal way to synchronize data from different data sources or surveys (for example, one for the population census and the other for indigenous communities, both with different records and variables).

1.- It should only be done in different applications, each one in their respective Data Entry


2.- It is possible with a AppMenu to synchronize both sources with a single connection and with calls sequentially to the different data synchronization function
Elemplo:
SYNCCONNECT (Bluetooth);
SYNCDATA (PUT, CENSUS_DICT);
SYNCDATA (PUT, INDIGENOUS_DICT);
SYNCDISCONNECT();


3.- It is possible with a AppMenu to synchronize both sources only with a connection and a call to the data synchronization function for each case
Elemplo:

Case 1:
SYNCCONNECT (Bluetooth);
SYNCDATA (PUT, CENSUS_DICT);
SYNCDISCONNECT();

Case 2:
SYNCCONNECT (Bluetooth);
SYNCDATA (PUT, INDIGENOUS_DICT);
SYNCDISCONNECT();

4.- There is another way that allows by programming logic to control different dictionaries that point to the same file names but different dictionaries and it is not documented in the examples.

In advance, thanks for your wise advice and guidance
aaronw
Posts: 561
Joined: June 9th, 2016, 9:38 am
Location: Washington, DC

Re: Synchronization of two or more data sources

Post by aaronw »

1. A single menu could synchronize data from multiple surveys. However, I would recommend one menu per survey. This keeps things organized and separate. I wouldn't want an interviewer using a menu that gives them access to surveys they aren't actively working on. In my experience you're asking for trouble.

2. Syncing CENSUS_DICT and INDIGENOUS_DICT is no different than synchronizing multiple external dictionaries which I do in all my surveys. I've just never allowed a menu to control multiple surveys.

3. Yes, you can connect, sync, disconnect, and repeat as many times as you want. What is your motivation? Do you want to synchronize to another Dropbox account?

4. Can you clarify your question? I'll just mention setfile can be used to point the dictionary to different data files: https://www.csprousers.org/help/CSPro/s ... ction.html
vgonzalez
Posts: 27
Joined: March 12th, 2020, 4:19 pm
Location: VENEZUELA

Re: Synchronization of two or more data sources

Post by vgonzalez »

Thanks Aaronw,

I just want, based on your recommendations, identify which of the options would be the ideal one to transmit the complete data collected at the end of the day, depending on the incidents in the field, you can register complete cases from the first dictionary, or complete cases from the second questionnaire , or complete cases from both dictionaries, depending on it:

If the interviewer after finishing his day to transmit the data to his supervisor, should do it separately?

From the four previus options, I would to know which is the most appropriate to transmit the complete data to the supervisor, specifically if I have to pass two data sources, should I make two connections or just one?

I consult it because it generated the following message:

Error in Bluetooth
synchronization. Expecting more data from other device. Either the connection was lost during the transfer ot the other device did not properly end the session by calling syncdisconnect
aaronw
Posts: 561
Joined: June 9th, 2016, 9:38 am
Location: Washington, DC

Re: Synchronization of two or more data sources

Post by aaronw »

If the interview is working on both surveys and the supervisor is responsible for collecting the data from both, then I would considering implementing a single menu option to transfer all data. With the goal of making the process less error prone (less details for the interviewer and supervisor to remember).

Make sure to check the result of the syncconnect in an if statement.
if syncconnect(Bluetooth) then
    syncdata
(PUT, CENSUS_DICT);
   
syncdata (PUT, INDIGENOUS_DICT);

   
syncdisconnect();
endif;
Post Reply