cancel
Showing results for 
Search instead for 
Did you mean: 

Smart Synch replication error

Former Member
0 Kudos

Hi all,

I am trying to set up the example application for the Contact tutorial (smart synchronization). I made all steps (SyncBO, client application), and the application runs in the Mobile Client. However, when I try to replicate data from the backend to the middleware using merep_ex_replic, I get error message: the SyncBO doesn't exist.

When I debugged the replication application I found that for S01 type SyncBO (2-way synchronization using BAPI wrappers) the replication won't work. In merep_804 table the FMCAT field is 'D', instead of 'R' and the replication program is looking for fmcat='R' type record.

Does anybody know why is this? Should I use Timed 2-way synchronization instead? (there's fmcat='R' for type). What's the difference between the 2 types?

Thanks in advance,

Pál Somogyi

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

you can change it using merep_sbuilder transaction

while in Change SyncBO Attribute there is a tab 'Administration' in which there is a check-box option Default Async.

To make your data transfer type Sync you can uncheck this option.

Regards

Divya

<b>For Useful answers you can rewards points. to prev queries as well</b>

Former Member
0 Kudos

Hi,

thanks really for your time and help. Your answers helped me a lot.

Bye,

Pal

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi PAL,

You can set the synchronous mode as Asynchronous or Synchronous while designing the synco..

In attributes can check async or uncheck that..

By defalut its async.

This is design time change....we can set this mode in runtime also..that need lill bit coding..:)

Cheers,

Karthick

Former Member
0 Kudos

Hi Pal,

Initial (default generated code) will not allow you to create,modify,delete records from the client.

The generated code enables you to getlist,getdeatil.

Code has to be written manually by the developer using NWDS.

Cheers,

Karthick

Former Member
0 Kudos

Hi,

thanks for the answers, they were really helpful. I found several good documents on the api, and a thorough example, similar that the NWDS has on general synchronization.

One more question: where can you set synch/asynch mode of the syncBO? I found one suggestion that you have to modify the generated xml file, but is there a step while you create the syncBO? I didn't see it anywhere.

Thanks,

Pal

Former Member
0 Kudos

Hi,

ok I found out that for s01 synchronization data download is triggered by the mobile device. So replication is not available for this. The problem is that no data is downloaded when I press the 'Synchronize' button. Now the question is: does anybody know how to configure the syncbo to start the download?

Thanks,

Pal

Former Member
0 Kudos

Hi Pal,

You are correct that there is no synchronization for S01 type of syncbo.

Make sure that the syncbo is generated properly, enabled in merep_pd.

Also make sure that data (records) exists in backend for the syncbo.

If there is any relation shipt between other syncbo..make sure that parent syncbo (data) is present in middleware...(Cascade relationship).

merep_10100 is the DB table for S01 type of Syncbo.

Hope this is helpful.

Cheers,

Karthick

Former Member
0 Kudos

Hello Pal,

how many times are you triggering Synchronization.

I guess you have chose async option while creating the syncBO

So when you sync once the data will be posted, and try syncing more than twice. this might help.

to add to your application:

S01 is one of the simplest types, but i would suggest T51 type syncBO if you have large data, it only affects the middleware.

if the data in your application changes quite frequently only then go for S01 type.

Hope this helps.

Regards

Divya

Former Member
0 Kudos

Hi,

thanks for your replies. There was an error in the syncBO, I found it with merep_mon, and after I corrected it, the application works, I can see contact data. And yes, I had to synchronize more than once.

I would have another question though. From the meRepMeta.xml generated from the syncBO, the Smart Synch project wizard generates code (java and jsp files) for viewing the data. But it didn't generated code for create, modify or delete the data. Is there a configuration settings for this, or this part of code (upload) is never generated? In the syncBO I have specified all the function modules (list, details, create, modify, delete) and made the mapping for them. Could you give me example code how to synch data back to the backend?

Thanks in advance,

Former Member
0 Kudos

Hi Pal,

well, that might be a asyn data transfer in your case.

Client Development:

You have now the auto generated code with you in NWDS. since your func modules are of said types you can do these from client side too. for these you need to write code yourself.

there is no configuration settings for code generation. the application generate gives a basic functionlity of viewing the BE data.

To create, modiy and delete you need to write your code. it is anyway there. just modify if needed.

At the bottom of the SmartSyncDBAccess file you will see code for modify and create SyncBO. remove the comments and use the code. you can call it directly in your application.

this gives you an idea. debug and change the code to suit your needs.

Hope this helps.

Divya

to understand the code better you first need to understand the SmartSync APIs.