Articles in this section
Category / Section

How to give access for custom JSON using PostgreSql data source?

Published:

The Bold BI application allows you to access custom JSON data using a PostgreSQL data source by following these steps.

Steps to access custom JSON data in Bold BI

  1. Refer to the Connecting Bold BI to PostgreSQL data source documentation for successful connection.

  2. Drag and drop the table that has the JSONB data type in Bold BI, as displayed in the image below.

    drag-table.png

    NOTE: The JSONB data type will be hidden in the data preview, but it can be accessed by creating expressions in Bold BI.

  3. Click Save to save the data source with a relevant name in order to proceed with designing the dashboard.
    save-option.png

    Note: You can also create expressions on the data source page itself:

    Configuring Expression Columns

  4. Drag and drop the Grid widget and click on the Assign data section to start creating expressions.
    grid-widget.png

  5. Click on the Add Expression button as shown in the following image.
    expressions-button.png

  6. Then add the JSON path value in the Expression editor as shown in the following image and click Save.
    add-expressions.png

    Operator Usage
    -> The operator -> returns the JSON object field by key.
    ->> The operator ->> returns the JSON object field by key as text.
    Index Index(0) is used to filter data from array without using a key.
  7. Assign values to the widget as shown in the following image.

    assign-values.png

  8. Now, you can view the JSONB data retrieved from the PostgreSQL server and visualize it in Bold BI as shown in the following image.

    grid-jsonb-data.png

  9. You can also access the JSONB data using queries in a code view mode. Switch to the code view by enabling the toggle option in the tools pane in the data design view, as shown in the following image.

    code-view-mode.png

  10. In the Query Editor Window, you can enter the query that helps access JSONB data. After entering your query, click the Run icon in the tools pane.
    altered-query.png

  11. You can view the data for your query at the bottom of the Query Editor by clicking Update.

    jsonb-data.png

Was this article useful?
Like
Dislike
Help us improve this page
Please provide feedback or comments
NG
Written by Nisanth Gunasekaran
Updated:
Comments (0)
Please  to leave a comment
Access denied
Access denied