# Setting a Grafana Dashboard using the Athena plugin

#### &#x20;Visit [<mark style="color:blue;">**Grafana.com**</mark>](https://grafana.com/), click 'data sources' and then click 'Add new data source'.

<figure><img src="/files/gqLrdyyvhShWeRQniSqG" alt=""><figcaption></figcaption></figure>

#### Get plugin >> Amazon Athena >> Install Plugin

<figure><img src="/files/XQoTlI4HBRmzXSfQw99v" alt=""><figcaption></figcaption></figure>

#### 'Amazon Athena' plugin is added,

<figure><img src="/files/7HLLnDO2LQctk7Cd1wSA" alt=""><figcaption></figcaption></figure>

#### Return to AWS IAM settings, select the 'Users tab', and click 'Create User. '

<figure><img src="/files/WB6Xrnc67g3agXEwI6rt" alt=""><figcaption></figcaption></figure>

#### Specify the user details and click 'Next'.

<figure><img src="/files/OOMty73ek6CpPZCq3Bo3" alt=""><figcaption></figcaption></figure>

#### To set permissions, select 'Attach policies directly'.

<figure><img src="/files/heyR51Vp6SSz5BOYwyCX" alt=""><figcaption></figcaption></figure>

#### Select from the existing policies.

<figure><img src="/files/EA7g7JDoQ9oMEL28iLeK" alt=""><figcaption></figcaption></figure>

#### Click 'Create user'

<figure><img src="/files/aRQjLEhvQobxwzoWoSuc" alt=""><figcaption></figcaption></figure>

#### Create the Access Key.

<figure><img src="/files/cyrgWZ2tFlqWG2Jn3DPG" alt=""><figcaption></figcaption></figure>

#### Select 'Others' and click 'Next.'

<figure><img src="/files/vj7vifQGnS2B1MPEHBct" alt=""><figcaption></figcaption></figure>

#### Set Description tags if required, and click 'Create access key'.

<figure><img src="/files/6jaqo3P8KujKACqabvzu" alt=""><figcaption></figcaption></figure>

#### Once the Access key is created, copy and save both the access and the secret access key, or download them as a .csv file and click 'Done'.

<figure><img src="/files/8mY2ld4cKcveZgQQKzOD" alt=""><figcaption></figcaption></figure>

#### Now go back to Grafana to specify the Athena dashboard's settings and click 'Save and test.' Ensure that the output location is a folder in the S3 bucket.

<figure><img src="/files/WruGBX6q3xZ6pOLpsCPV" alt=""><figcaption></figcaption></figure>

#### Once the data source is tested, this message is displayed.

<figure><img src="/files/qP7cesCSrzEsaEzx0VKm" alt=""><figcaption></figcaption></figure>

#### Click 'Dashboards', click 'New' and then click 'New dashboard'.

<figure><img src="/files/IMQ8oPD66iLrNfti250m" alt=""><figcaption></figcaption></figure>

#### Click 'Add visualization'.

<figure><img src="/files/ZS3YwAQjk6Zp9bcLxIoN" alt=""><figcaption></figcaption></figure>

#### Select the data source.

<figure><img src="/files/aAX1kvUPdqheJm0qpGAT" alt=""><figcaption></figcaption></figure>

#### This opens the basic dashboard screen.

<figure><img src="/files/LynBwt5d6mBuZc7ZFTHk" alt=""><figcaption></figcaption></figure>

#### Add your query and then click 'Run query'.

For example

<figure><img src="/files/X1FwMwYw2eUFt0rRzBAc" alt=""><figcaption></figcaption></figure>

#### Editable Format

```python
SELECT
    $__timeGroup(time, $__interval) as Time,
    AVG("$__column") as Alt
FROM
    "$__table"
WHERE
    $__timeFilter(time)
GROUP BY
    $__timeGroup(time, $__interval)
ORDER BY
    Time ASC

```

<figure><img src="/files/OOulSBA21z6ipn785Aik" alt=""><figcaption></figcaption></figure>

#### The Dashboard is created.

<figure><img src="/files/YU5vGtyYTQwalwAZsDhc" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.influxtechnology.com/support_guides/rexgen-series-product-manuals/rexgen-air-cloud-usage-guides/cloud-usage-guides-for-rexgen-air-device/setting-grafana-dashboard-with-parquet/setting-a-grafana-dashboard-using-the-athena-plugin.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
