on 04-21-2008 4:33 PM
Hi experts, i have an application in MI 7.0 with various syncbo...
I have syncbo ZSBOE001 and syncbo ZSBOE002.
I write 'hi' from device in syncbo ZSBOE001, i sync, write in the table 'hi' and write in the table of syncbo ZSBOE002...
When return in the device, the new data that should be in ZSBOE002 not appear... I need do two sync... I understand why, but, how can avoid it? If i do two sync, it take long time.
Thanks,
PD: i intent:
Vector s = new Vector();
s.addElement("ZSBOE001");
sincronizar(s, SyncBoDeltaRequestType.DIRECT_REQUEST);
s = new Vector();
s.addElement("ZSBOE002");
sincronizar(s, SyncBoDeltaRequestType.REQUEST);
private void sincronizar (Vector syncbos, SyncBoDeltaRequestType tipo) {
SyncBoDescriptorFacade descriptorFacade = SmartSyncRuntime.getInstance().getSyncBoDescriptorFacade();
if (syncbos.contains("ZSBOE001")) {
SyncBoDescriptor syncBoDescriptorE1 = descriptorFacade.getSyncBoDescriptor("ZSBOE001");
SmartSyncRuntime rE1 = SmartSyncRuntime.getInstance();
rE1.getSyncBoDeltaRequestFacade(VisibilityType.USER_SHARED).getSyncBoDeltaRequest(syncBoDescriptorE1).setProcessing(tipo);
}
else {
SyncBoDescriptor syncBoDescriptorE1 = descriptorFacade.getSyncBoDescriptor("ZSBOE001");
SmartSyncRuntime rE1 = SmartSyncRuntime.getInstance();
rE1.getSyncBoDeltaRequestFacade(VisibilityType.USER_SHARED).getSyncBoDeltaRequest(syncBoDescriptorE1).setProcessing(SyncBoDeltaRequestType.NO_REQUEST);
}
if (syncbos.contains("ZSBOE002")) {
SyncBoDescriptor syncBoDescriptorE2 = descriptorFacade.getSyncBoDescriptor("ZSBOE002");
SmartSyncRuntime rE2 = SmartSyncRuntime.getInstance();
rE2.getSyncBoDeltaRequestFacade(VisibilityType.USER_SHARED).getSyncBoDeltaRequest(syncBoDescriptorE2).setProcessing(tipo);
}
else {
SyncBoDescriptor syncBoDescriptorE2 = descriptorFacade.getSyncBoDescriptor("ZSBOE002");
SmartSyncRuntime rE2 = SmartSyncRuntime.getInstance();
rE2.getSyncBoDeltaRequestFacade(VisibilityType.USER_SHARED).getSyncBoDeltaRequest(syncBoDescriptorE2).setProcessing(SyncBoDeltaRequestType.NO_REQUEST);
}
SyncManager syncManager = SyncManager.getInstance();
syncManager = SyncManager.getInstance();
syncManager.synchronizeWithBackend();
}
But the sync continue in synchronous mode... and i can´t do nothing with the device.
Edited by: Victor Capi on Apr 21, 2008 5:34 PM
Victor,
the solution in your case is easily to use a syncBO with a header and child structure - then the info is in one BO - and so it will come down in one sync usually. The only solution to avoid that while using two BOs:
Write your own sync
and sync two times sutomatically if Item A changes.....
Regards,
Oliver
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
NOP!
Well, it is the GETDETAIL return that can deliver structures - go to your ABAP guy and talk to him about this structure.
If the two items are linked anyway, you can have a header and then the related entries from the second table as items. But he should know how to do that in ABAP.
But as far as I am aware off : you can not trigger the download of a second BO from the first one ...
Regards,
Oli
Edited by: Oliver Kaluscha on Apr 22, 2008 2:41 PM
Hi,
well, the abaper does not know what you change - but he does not need to know..... And if he wants he knows it.... he has a MODIFY handler. You can not change the KEY, so this stays the same. So he selects the item for update based on the key - and then he takes your values and updates the item he selected with your entries - and persists it. Where is the issue?
Regards,
Oliver
User | Count |
---|---|
98 | |
11 | |
11 | |
10 | |
10 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.