Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

Since version 3.1.0-KickOff, Ontologies have been referred to as "Entities" in the Control Panel. This does not alter any functionality; the nomenclature has simply been changed for a better understanding of the concept.

User Interface: 5.3.2-Ultimate

Introduction

We have the possibility to create an Entity from a data file we have, either in CSV, XML or JSON format, using the defined structure and importing the data from the file.

For this guide, we are going to see how to import the following JSON file:

Steps

Create the Entity

From the Control Panel, navigate to the Development > My Entities menu.

image-20240403-142732.png

This will take us to the list of available Entities. To create the Entity, click on the "+" button at the top right of the screen.

image-20240227-121951.png

From the different Entities that we will be able to create, we will select the "Creation from File" one:

image-20240404-135744.png

Upload the file

To create the Entity, we are going to make use of the Platform's export and import tool, with the addition that it will allow us to create a new Entity with the data, or reuse an existing one.

The first step is to upload the file with the data to the Platform. To do this, click on the "Click to upload" button, which will open the file selection window of the operating system.

image-20240404-135905.png

There, we will look for the file we want to import (in this case, the "data_example.json" file that we can download at the top of this page).

image-20240315-093711.png

Once it has been uploaded, we will see that of the two code screens that appear at the bottom, the one on the left has been populated with the file we have uploaded:

image-20240404-140227.png

In case the code is not formatted, we have the option to do so by clicking on the "Beautify" button.

The next step will be to generate the schema of the Entity from the file we have uploaded. To do this, click on the "Generate JSON Schema" button. We will see that in the code window on the right the data schema is displayed:

image-20240404-140456.png

Import options

When importing data, we have a few options available:

  • New Entity: as previously mentioned, we have the option of creating a new entity from the data we have loaded, or importing such data to an existing Entity. By default a new Entity will be created. If we want to import the data to an existing Entity, we uncheck this box and an Entity selector will appear, where we can choose on which one to import the data. It is important to note that the data must have the same structure as the schema of the Entity.

image-20240404-140616.png

  • Import data to RTDB: if this option is checked, when the Entity is created the data will be automatically loaded into the Entity. If unchecked, the Entity will be created but empty, without importing data into it (this is useful for creating a structure from test data).

  • ContextData Enable: if this option is enabled, the Entity created will have contextual data. By default, it will be created as an Entity without ContextData.

Once the options have been decided, click on the "Create" button to complete the creation of the Entity.

image-20240404-140739.png

Create a new Entity

If a new Entity is being created, when clicking on the "Create" button, a window will appear in which you will have to enter the general information typical of Entities:

  • Name: this will be the unique identifier of the Entity.

  • Description: a short descriptive text of the Entity, such as its utility, use, etc.

  • Storage: the database where the Entity will be stored, which by default will be the Platform's native database, MongoDB.

image-20240404-141037.png

Once the necessary information has been entered, clicking on the "Create" button will create the Entity.

image-20240404-140739.png

Depending on the options defined, a series of notifications will be displayed to warn of the result of the operations performed.

image-20240404-141208.png

A window will then be displayed with the available options to be performed with the Entity created.

image-20240404-103707.png

Clicking on the "Close" button will take you back to the Entities list, where the newly created Entity will appear.

image-20240401-140734.png

Consulting the information

In case we have imported data into the newly created Entity, we can use the query tool to check our data.

To do this, access the Tools > Query Tool menu.

image-20240404-141459.png

In the window that will appear, select the Entity for which you want to consult the information, and execute the relevant query.

image-20240404-142036.png

  • No labels