1. Home
  2. Knowledge Base
  3. FAQs
  4. How to create custom entities on Hubway Connect

How to create custom entities on Hubway Connect

Custom entities are virtual entities, a combination of entities that relate to each other. Think of it as a view. Custom entities are like any other in your project, so please name them to your liking.

Custom entities are helpful when you need:

Organise data: to ensure that everyone uses the same dataset. For example, you have a custom entity that creates the raw data needed for all financial reporting. Having all reports use this custom entity means everyone works from the same data set.

Unify data: to create a dataset from multiple entities and simplify the dataset (instead of joggling with multiple tables/sections)

Restricting access: to limit access to data. For example, only users from a country/department/client may access data from that area.

 

1st: Select the primary entity

Select primary entity

 

Hubway will then display every related entity to the primary entity in the first layer (Level 1). These entities are all related to the primary entity via a foreign key.

Primary entitiy demo

 

2nd: Adjust the Entities

Hubway will suggest entities that are linked to the entities that are already added to the custom entity. This will be displayed under levels depending on the relationship between entities. You can have as many levels as you want. The entities displayed at a specific level are directly related (via foreign key) to the selected entities at the previous level.  By default, all entities are selected in the first level. Select only the required entities for your custom entity.

Adjust entities demo

 

You can further customise the relationship between the selected entities by changing the type of join: INNER, LEFT or FULL.

Adjust entities relationship

 

3rd: Adjust Attributes

The attributes of all selected entities are displayed on the right side. They are indented according to which entity they belong to.

You can:

  • filter each field according to the data type
    • each data type has a tailored list of available operators
    • the input field of the filter value is data type smart
      • Boolean fields only accept true or false
      • A datepicker will be displayed for date/datetime values
      • A dropdown with the related records is displayed for foreign keys to static entities
  • select/unselect fields in which unselected attributes will not be part of the output

 

Adjust attributes

 

Observations

You can view the query generated once the custom entity is created and edit it by clicking on the customise button.

Observations

In the Project, the custom entity will act as any other entity. However, the output of all the selected joins in the custom entity is a flat table.

Custom entity is a flat table

Was this article helpful?

Related Articles