This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Sync Project - inserting objects works but not the update

Hi Experts, 

I'm having a really bad time trying to make a synchronization project to work. Almost there but can't find the missing configuration to make the update work when calling the synchronization workflow from a process (ADHocProjection). 

I have the following:

  • SQL DB Sync project
  • Using stored procedures for Insert/Update/Delete. For the updates I'm using "Script based" data operations, and "Pattern based" for Inserts and Deletes.
  • Sync project is being used for Provisioning only (1IM > Target System)
  • Adding or updating an object works fine from the "Target system>Browse" functionality within the Synchronization Editor.
  • Running a simulation or executing the sync workflow works fine. Meaning it detects when is an insert/update on an object and it runs the Stored Procedures defined.
  • (Tricky part) the mapping is between 1IM.UNSAccountBInUNSGroupB > DBTargetSystem.Accounts, since Account and Role membership represents an Account in the target system.
    • User can be a member of only one role (UNSGroupB) at the time.
    • Insert is triggered when there is a new record in UNSAccountBInUNSGroupB and there is no matching Account in the target system.
    • Update "should" be trigger when there is a new record in UNSAccounBInUNSGroupB but there is already an Account in the target system.
  •  When running the Sync workflow from a process task (on insert in UNSAccounBInUNSGroupB table) the provisioning log shows: "There are no changed objects logged for this synchronization log". This only happens when the Account exists in the Target System, so when it suppose to run an update and not an insert. 

Any suggestions? Tips?

Thanks,

JM 

Parents
  • Hey Rob,
    I'm using now the Assign and Remove events as you suggested, I switched it to Insert/Delete when testing (process was not triggering) but now that you mentioned it I replace it back with the proper events and is triggering as expected.

    The DPR_GetAdHocData() returns the right workflow to call, and I'm able to see the log in the Sync Project, so it means it was triggered and the workflow/mappings should detect what to do (insert/update/delete).

    I'm using a workaround that includes another mapping and workflow, the mapping has a faulty matching rule, therefore when the workflow/mapping is called it won't find a corresponding object in the target system, so it will run the Insert stored procedure.

    That workaround works in my case since the store procedure is the same for inserts and updates. The delete event (from Remove on UNSAccountBInUNSGroupB) is using another workflow/mapping so it can detect the matching object in target system and proceed with the delete.

    Maybe my logic is wrong, or am I missing something?

    Thanks for your input Rob, and if you see something else in my configuration please let me know.
    JM
Reply
  • Hey Rob,
    I'm using now the Assign and Remove events as you suggested, I switched it to Insert/Delete when testing (process was not triggering) but now that you mentioned it I replace it back with the proper events and is triggering as expected.

    The DPR_GetAdHocData() returns the right workflow to call, and I'm able to see the log in the Sync Project, so it means it was triggered and the workflow/mappings should detect what to do (insert/update/delete).

    I'm using a workaround that includes another mapping and workflow, the mapping has a faulty matching rule, therefore when the workflow/mapping is called it won't find a corresponding object in the target system, so it will run the Insert stored procedure.

    That workaround works in my case since the store procedure is the same for inserts and updates. The delete event (from Remove on UNSAccountBInUNSGroupB) is using another workflow/mapping so it can detect the matching object in target system and proceed with the delete.

    Maybe my logic is wrong, or am I missing something?

    Thanks for your input Rob, and if you see something else in my configuration please let me know.
    JM
Children
No Data