HOME COMMUNITY BLOG

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

If you want to create a hierarchical data structure, e.g. Invoice with InvoiceDetail, you have to create relationships between entities. After specifying a relation, you have to specify keys for it.

Attributes

RelatedEntityPoints to the entity to which an entity has a relation.
IsSelfJoinDeprecated. Do not use.
IsOr

When the relationship has multiple keys they are normally rendered as "EntityA.Key1 = EntityB.refEntityAKey1 AND EntityA.Key2 = EntityB.refEntityAKey2".

When set to True, OR will be used between keys instead of AND.

IsParentChild

Indicates that the base entity is a parent and the entity we are relating to is a child. By setting it to True, the following attributes are activated:

  • Cascading Delete: When data structure contains both parent and child entities, by deleting parent also child records are deleted.
  • Nested XML: Tags will get nested, which will result in faster XSL Transformations and the XML document will be easier to read.

Info
titleWarning

Set IsParentChild only where child records are not linked to more than 1 parent. Otherwise you will get the "A child row has multiple parents" error after reading data to a data structure which contains this relation.

Example XML nesting if IsParentChild = False

Code Block
languagexml
<Parent/>
<Parent/>
<Child/>
<Child/>

Example XML nesting if IsParentChild = True

Code Block
languagexml
<Parent>
  <Child/>
  <Child/>
</Parent>
<Parent>
 <Child/>
 <Child/>
</Parent>

Child Elements