Explore data in Grafana
Last updated on October 23, 2024
Introduction
The AccelByte Intelligence Service (AIS) Grafana Dashboard comes with a query tool that you can use to perform ad hoc queries, providing a flexible and dynamic way to explore and understand your game data in greater depth.
This query tool is available on the Explore page in your AIS Grafana account.
Run query with builder
- In your AIS Dashboard, click on the Explore menu.
- On the Explore page, choose AIS data warehouse as your data source.
- To activate the filtering, grouping, and ordering in the Query Builder, turn on the Filter, Group, and Order toggles.
- Choose the Table from your database. For example, choose
user_t
. - In the Column panel, select the column of the table. For example, choose
namespace_t
and fill the Alias with"NAMESPACE ID"
. - Click on the the add (+) button in the Column panel to add another column, and then do the following:
- Select
*
as the column. - Set
COUNT
as the Aggregation. - Fill in the the Alias with
"Total user"
.
- Select
- In the Filter by column value panel, click on the add (+) button to add filtering, and then do the following:
- Select
ctime
as the column filter. - Set
>=
as its operation - Set
2024-01-01 16:05:08
as the value.
- Select
- Click on + Group panel to add grouping setting, and then select
namespace_id
. - In the Order by panel, do the following:
- Set the order to
COUNT(*)
. - Set the order style to
DESC
(descending). - Use
50
as the limit.
- Set the order to
- Click on the Run Query button to view the results.
Run query with code
- In your AIS Dashboard, click on the Explore menu.
- On the Explore page, choose your choose AIS data warehouse as the data source.
- Click on the Code button.
- Fill the text box with this query:
SELECT
namespace_id AS "Namespace ID",
COUNT(*) AS "Total user"
FROM
user_t
GROUP BY
namespace_id
ORDER BY
COUNT(*) DESC
LIMIT
50 - Click on the Run Query button to view the results.