What is AMQL?
AMQL is the analytical language powering Holistics 4.0
What is AMQL?
AMQL (Analytics Modeling and Querying Language) is an analytical language centered around metrics. Using AMQL, analysts define analytics logic in our centralized metrics layer, and query them using our metrics-centric query language. AMQL is designed to be business-friendly, easy to use and highly reusable.
AMQL consists of 2 inter-connected components:
- A metrics / data semantic layer (AML - Analytics Modeling Language): a declarative language used to describe data semantic model and business metrics.
- A query language (AQL - Analytics Querying Language) that leverages data semantic model defined to query SQL databases in a higher abstraction manner, especially composing and reusing metric-based queries.
AMQL is designed for data engineers, data analysts, analytics engineers, or anyone who works with analytics queries and want better reusability, composability, development productivity than currently possible with existing tools.
AMQL allows you to quickly implement analytics use cases that are typically complicated in SQL. Things like Percent of Total, Nested Aggregations, Level of Details, among other things.
Metric-centric Thinking
AMQL follows “metrics-centric thinking” paradigm. AMQL allows users to query data at a higher abstraction level, closer to how business users operate. This makes AMQL more accessible to non-technical users compared to SQL.
A query in AMQL revolves around metrics and dimensions. These metrics and dimensions are defined beforehand by analytics team.
Check out Metrics-centric Thinking for a more detailed writeup.
Why we built AMQL?
We strongly believe in the vision of analytics as-code as the future of BI and analytics. However, in our opinion, there is not an adequate existing analytics-as-code language.
Firstly, we believe there is a need for a declarative language to define semantic model, similar to how Ansible and Terraform revolutionized the way infrastructure is defined in code. When we look at existing declarative languages, there are languages like XML, JSON or YAML but each of them has their own limitations. The most suitable language is LookML but it is proprietary and only works with Looker.
Secondly, we also believe there is a need for a new query language that can leverage the semantic model defined in the first language, built to be concise, expressive while also suitable for adhoc analysis. We believe SQL is too low level as a language and solution like adding templating language (like dbt’s Jinja use) on top is just a band-aid.
Thus, in order to realize this vision, we created AMQL to be a complete analytics-as-code language.
Installation
AMQL is currently only available in Holistics Cloud. Support for self-hosted installation will come in future versions.