Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9190

Re: Setting 1 to Many Associations and possible help represeting on screen

$
0
0

Hello Alexander,

 

with associations in BODL you have two possibilities:

  • Keywords "using"
    • You need an Alternative Key at the target node.
      By definition an Alternative Key identies uniquely a single node instance.
      Therefore this kind of association can have the multiplicity
      • [0,1] = optional
        or
      • [1,1] = mandatory
    • Every Custom BO node has one Alternative Key typed by UUID automagically
    • You can define your own Alternative Key with the annotation [AlternativeKey] for any node.
    • You can define multiple Alternative Keys, but only one with the same type.
    • SAP BO may have none, one or many Alternative Keys per node.
      Use the keyword "using" to choose the right one.
    • If there is a UUID-typed Alternative Key at the target node the keyword can be omitted
  • Keyword "valuation"
    • You compare values of the target node with constants or values from the source node.
      Such a comparison may fit for none, one or many node instances.
      Therefore this kind of association can have the multiplicity
      • [0,1] = optional, one hit
      • [1,1] = mandatory, one hit
      • [0,n] = optional, none, one, or many hits
      • [1,n] = mandatory, none, one, or many hits
    • On the left hand side of the comparison only elements from the target node are allowed.
    • On the right hand side of the comparison either
      • elements from the source node are allowed
      • constant values are allowed
    • You can combine several comparison (lines) via the '&&' operator
    • The target node must be inside the current Custom BO definition
    • If the target node is the Root node, the association targets another instance of the same Custom BO
    • For any other nodes the association targets a node instance in the same Custom BO instance

 

So, form your example above I suggest to use your approach:

 

businessobject MyBO {

  element MyId : ID;

  node ToOtherBONodes [0,n] {

    association ToOtherBO [0,1] to AP.FO.BusinessPartner.Global:Employee;

  }

}

 

HTH,

    Horst


Viewing all articles
Browse latest Browse all 9190

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>