SAP Knowledge Base Article - Public

3579009 - Administrative Data not created on new instances of nodes of Custom BO

Symptom

Instance created via BeforeSave does not have SAP_SystemAdminstrativeData.

Environment

  • SAP Business ByDesign
  • SAP Cloud Applications Studio
  • SAP Cloud for Customer

Cause

This is a limitation as the framework does not support cyclical determinations. This is as expected, because if cyclic determinations were theoretically supported from the beginning, partner coding could run into frequent infinite loops resulting in massive system hangs. 

The calculation of System Administrative Data for any created/modified instance of child is executed, followed by the BeforeSave of that instance, followed by the BeforeSave of Root.

When the creation of the child is triggered via the BeforeSave, the subsequent determinations for child will not be triggered again. This is because, this would now be a cyclic determination in the same execution layer (in this scenario, our execution layer is the PDI one) on the same Business Object, in the same execution time-point (Save(Finalize)).

  1. DETERMINE_ADMINISTRATIVE_DATA
  2. CHILD-YXXXXXXXY_DET_BEFORE_SAVE 
  3. ROOT-YXXXXXXXY_DET_BEFORE_SAVE

In short, DETERMINE_ADMINISTRATIVE_DATA will not get called again for any child node to prevent looping.

Resolution

The only way to overcome this limitation, is to move the creation code logic to the AfterModify event.

Keywords

PDI, before save, after modify, SDK, subnode, determinations, Change History, WithAdministrativeData , KBA , AP-RC-BDS-BO , ByDesign Studio BO definition/generation , Known Error

Product

SAP Cloud Applications Studio all versions ; SAP Cloud for Customer add-ins all versions ; SAP Cloud for Customer core applications all versions