Search results

Connecting Bold BI to Amazon Athena data source

The Bold BI Dashboard Designer supports connecting the Amazon Athena database using the SQL Live Query (C# API).

Choose an Amazon Athena data source

To configure the Amazon Athena data source, follow these steps:

  1. Click Data Sources in the configuration panel to add a new data connection.

Data source icon

  1. Click CREATE NEW to launch a new connection from the connection panel.

Create new datasource

  1. Select the Amazon Athena connection in the connection panel.

Amazon Athena icon

NOTE: You can also create a data source from the home page by clicking the Data Sources menu from the left menu panel and Create Data Source from the data sources page.

Amazon Athena connector

Connect to Amazon Athena

Amazon Athena data source can be accessed in Bold BI using the live connection mode.

Create Amazon Athena data source

After clicking the data source, the NEW DATA SOURCE configuration panel opens. Follow the given steps to create an Amazon Athena data source:

  1. Enter a name and description (optional) for the data source.
  2. Choose the region endpoint of the server from the Region Endpoint drop-down.
  3. Enter the port, in which the server is running in the AwsAccessKeyID text box.
  4. Enter a valid Amazon Athena secret key in the AwsSecretKey text box.
  5. Enter a valid output location for storing the output files in the Output location text box in the format mentioned in the tooltip.
  6. Select a database that you want to query in the listed database associated with the given Amazon Athena server in the database combo box.

Amazon Athena connection details

Data preview

  1. Click Connect to connect the Amazon Athena server with the configured details. The schema represents the collection list retrieved from the Amazon Athena server. This dialog box displays a list of schemas in a tree view and their corresponding values.

Query designer page

  1. Now, the data design view page with the selected table schema opens. Drag the table.

Drag table

You can use the Code View option for passing a query to display data. Code view mode

  1. Click Save to save the data source with a relevant name.

NOTE: In the future, you can edit the connection information using the Edit Connection option.

Connecting Bold BI to Amazon Athena Data Source via REST API

Prerequisites

Type while creating the data source needs to be amazonathena.

Rest API - v4.0

Parameters for creating Data Source

Parameters Details
RegionEndpoint

required
`string`

Region in which the server is available

The region code must be provided. Examples: us-east-1, ap-south-1, and more. A list of available regions is provided in the following link.

The available AWS regions


AwsAccessKeyId

required
`string`

AWS access key of the account.
AwsSecretAccessKey

required
`string`

AWS secret key of the account.
OutputLocation



required
`string`

A valid S3 location to store the query results. Format: s3://bucketname/foldername

The following link explains the s3 output location in Athena and its usage.
Output location in the Athena
Database

required
`string`

database which needs to be connected
Schemaname

required for table mode
`string`

Enter a valid Schemaname which will mostly be the database name.
Tablename

required for table mode
`string`

Enter a valid Tablename
Query

required for code view mode
`string`

Enter a valid Query
AdvancedSettings

optional
`string`

Additional optional connection parameters can be provided. By default, it is empty.
Expressions

optional

`Array of Objects`



Parameters for adding expressions when creating Data Source

Parameters Details
Name

required

`string`

Name of the Expression

Expression



required

`string`

Expression


Parameters for editing Data Source

NOTE: For editing Data Source via API. All the parameters are optional. The parameter which needs to be changed can be provided.

Parameters for modifying expressions when editing Data Source

Parameters Details
Name

required

`string`

Name of the Expression

Expression



required

`string`

Expression


Action



optional

`string`

add/delete/edit

By default, it is add.

NewName

optional

`string`

For renaming the expression. This is applicable only if the Action is edit

Connection Sample for Table Mode

For creating connection:

"Connection": [
{
"RegionEndpoint": "string",
"AwsAccessKeyId": "string",
"AwsSecretAccessKey": "string",
"OutputLocation": "string",
"Database": "string",
"Schemaname": "string",
"Tablename": "string",
"AdvancedSettings": "string",
"Expressions" : [{
"Name": "Expression1",
"Expression" : "SUM(numeric expression)"
    },
    {
"Name": "Expression2",
"Expression" :  "UPPER(string expression)"
}]
}
]

For editing connection:

"Connection": [
{
"RegionEndpoint": "string",
"AwsAccessKeyId": "string",
"AwsSecretAccessKey": "string",
"OutputLocation": "string",
"Database": "string",
"Query": "string",
"AdvancedSettings": "string",
"Expressions" : [{
"Name": "Expression1",
"Expression" : "SUM(numeric expression)",
"NewName" : "Sum",
"Action": "edit"
    },
    {
"Name": "Expression2",
"Expression" :  "UPPER(string expression)"
"Action": "delete"
}]
}
]

NOTE: Through Rest API, the data source can be created or edited with only one table. If different table is provided in edit data source, the table will be replaced. The widgets will be retained only if the schema is same as the previous table.

Connection Sample for Code View Mode

"Connection": [
{
"RegionEndpoint": "string",
"AwsAccessKeyId": "string",
"AwsSecretAccessKey": "string",
"OutputLocation": "string",
"Database": "string",
"Query": "string",
"AdvancedSettings": "string",
"Expressions" : [{
"Name": "Expression1",
"Expression" : "SUM(numeric expression)"
    },
    {
"Name": "Expression2",
"Expression" :  "UPPER(string expression)"
}]
}
]

Data transformation

Editing a data connection

Dashboard designer walk-through