Data Models

Data Models

Data Model Quick Start:

Managing Projects

Projects structure your data resources and business information enabling you to build models and visualize your data. A project may consist of several files and artifacts compiled to create a data model. The project serves as a unit for source control.

Creating a Project

  1. Select Develop > Data Models from the Home Navigation pane to open the Projects page.

    Projects page

  2. Click New Project.

  3. Enter the Project name.

    New Project

  4. Click Create. Your project is created.

    Empty Project

Managing Data Models

Here are the available data model controls within your project:

  • Files is the default view. Use + Add to add information to your data model. Use Search to find file names matching your search string. The files are listed in categories: Data Models, Tables and Others.
    • Edit icon Edit is available next to an item to edit the name.
    • Delete icon Edit is available next to an item to delete it.
  • Find and Replace searches for a string
  • Share shares the project with other bipp users.
  • Project Settings accesses options for the project.
  • Save saves the project.
  • Validate checks the SQL.
  • Deploy deploys the model so you can explore the data.
  • Options Menu displays the datasource Options menu.
    Options Menu
    • Revert to a previous version displays a list of versions. This option reverts the changes to the entire project.
      Revert version

    • View Datamodel displays the current data model.
      Display data model

There are several methods to populate your data model:

  • Create datamodel
  • Create table from datasource
  • Create table

Creating a Data Model

  1. Click Create datamodel from a new project or + Add > Add data model.
  2. Enter a name. Only letters, numbers and underscores (_) are allowed. Data model name
  3. Click the green check mark or use the Enter key.
  4. Create your SQL using the Visual Editor or the Code Editor.

Creating a Table from a Datasource

  1. Click Create table from datasource from a new project or + Add > import table from datasource Import table
  2. Select Datasource from the drop down. Refer to Datasources if you do not see your datasource.
  3. Search for a table to add, or expand the datasource and select the tables.
  4. Click Import.
  5. Create your SQL using the Visual Editor or the Code Editor.

Creating a Custom Table

  1. Click Create table from a new project or + Add > Add custom table.
  2. Enter a name. Only letters, numbers and underscores (_) are allowed. Custom table
  3. Click the green check mark or use the Enter key.
  4. Create your SQL using the Visual Editor or the Code Editor.

Editing the Data Model

Data model files are opened in tabs. Click on any file to open it. A red dot in the tab indicates unsaved changes.

Unsaved changes

Click on a Data Model to open it. There are two editors: Visual and Code.

Here is the data model in the Visual editor tab:

Visual Editor

Here is the same file in the Code editor tab:

Code Editor

Using the Data Model Visual Editor

Open the Visual editor tab. You see the Name- and **Label of your data model. These steps create a simple join. Refer to Visual SQL for detailed information on the Visual SQL editor.

  1. Click Tables + Add.
    Adding tables

  2. Select stocks and transactions. Click outside the selection box to close it.

  3. Click Joins + Add.
    Adding tables

  4. Select stocks for the left side and transactions for the right side.
    Adding a join

  5. Click the join icon. The join icon is red, indicating the join is undefined.
    Define the join

  6. Inner join is the default. For this example, select stocks.code from the left table and transactions.stock_code from the right table. Click outside the selection box to close it.
    Define the join
    The join icon is now purple instead of red.

  7. Click Validate to check your SQL. The editor reports any SQL errors.

  8. Click Save.

  9. Click Deploy. This step deploys your SQL to enable exploring the data model.

  10. Enter a Commit Message.

  11. Click Deploy.

Continue with Deploying the data model.

Using the Data Model Code Editor

Open the Code editor tab. There are commented lines to help you get started.

bipp helps you with query shortcuts:

  • Keyword Completion: As you type in the editor, bipp provides the relevant commands to assist you in creating your query. You can enter enough unique characters and use Tab or select it from the list with the mouse.
    Keyword Complete

  • Keyword Suggestion: bipp suggests keywords where possible. Keyword Suggestion

  1. Write your query. Here is a simple example:
    dataset retail_demo  
      table stocks transactions  
      join stocks inner join transactions  
        on stocks.code = transactions.stock_code

Code editor example

  1. Click Save.

  2. Click Validate to check your SQL. The editor reports any SQL errors.

Continue with Deploying the data model.

Editing Tables

Using the Table Visual Editor

Using the Table Code Editor

Deploying the Data Model

Once you have validated and saved your data model, it must be deployed before it can be explored.

  1. Click Deploy. This step deploys your SQL to enable exploring the data model.

  2. Enter a Commit Message.

  3. Click Deploy.

Your data model is now available for exploration. Explore your data model