Skip to main content
Version: 3.0

2.4.2 Relationships

Relationships define the connections between Target Entities in the knowledge graph. While Target Entities represent nodes, Relationships represent the edges that link them together.

Each Relationship connects a source entity to a target entity through their properties. The user specifies which property from each entity should be used to establish the connection. An Alias defines the label of the relationship in the graph (e.g., BELONGS_TO, CREATED_BY). For many-to-many connections, a Separator can be defined to split values in the source property.

Relationships can be created either through the menu or visually by drawing a line between two Target Entities on the Model canvas. Once processed through the Build operation, Relationships become visible and navigable in the Exploration module.

Create a Relationship​

There are two methods to create relationships between Target Entities: through the menu interface or visually on the Model canvas.

  1. Navigate to the Model section from the sidebar.

  2. Click the Add new button to add a new relationship.

  3. Click + Relationship to create a new relationship.

  4. Enter a title for the relationship.

  5. Select the source Target Entity from the dropdown.

    Select both source and target entities along with their connecting properties. The Actions section lists available actions, which will be enabled once the Relationship is established. You can use Reverse Relationship to quickly swap source and target.

  6. Select the source property from the dropdown.

  7. Select the target Target Entity from the dropdown.

  8. Select the target property from the dropdown. You can also configure optional settings:

    • Alias: The relationship label in the graph (automatically generated from the title, can be customized)
    • Separator: Split character for many-to-many relationships (if applicable)

  9. Click Save to create the relationship.

Visual Creation (Canvas)​

As an alternative to menu-based creation, you can create relationships visually by drawing connections on the Model canvas.

  1. On the Model canvas, click and drag from one Target Entity to another to draw a connection line between them.

  2. After drawing the line, a dialog opens where you can configure the relationship properties (entities, properties, alias, separator).

Relationship Configuration​

Alias​

The Alias is the label of the relationship as it appears in the knowledge graph. It defines how the relationship is named when queried or explored.

Automatic Generation:

  • The alias is automatically generated from the relationship title
  • You can customize the alias if needed
  • Changes to the title do not automatically update the alias once set

Naming Requirements:

  • Must not contain whitespaces
  • Must not contain special characters
  • Use underscore _ to separate words

Examples:

  • Title: "Belongs To" → Alias: BELONGS_TO
  • Title: "Created By" → Alias: CREATED_BY
  • Title: "Defined By" → Alias: DEFINED_BY
  • Title: "Has Parent" → Alias: HAS_PARENT

Separator​

The Separator serves as the split character for many-to-many relationship resolution in the Data Context Hub. When a source property contains multiple values (e.g., "value1,value2,value3"), the separator defines how to split these values to create multiple relationships.

Use Case:

  • A single record contains multiple related IDs in one field
  • The separator splits the field value to create individual relationships
  • Common separators: , (comma), ; (semicolon), | (pipe)

Example: If a property contains "123,456,789" and the separator is ,, three separate relationships will be created (one for each ID).

Reverse Relationship​

The Reverse Relationship function allows you to quickly exchange the source and target of a relationship. This is useful when you want to create a bidirectional connection or when you initially selected the entities in the wrong order.

What it does:

  • Swaps the "From Entity" with the "To Entity"
  • Swaps the "From Property" with the "To Property"
  • Preserves other settings (alias, separator)

Use Case: Instead of manually reconfiguring both sides of the relationship, use Reverse Relationship to instantly flip the direction.