Dataset syntax

(This feature is currently in active development. Please reach out if you want to become beta tester)


Please note that the dataset file has the extension .dataset.aml. Its full name is dataset_name.model.aml.

Dataset syntax definition

Dataset syntax defines the Dataset inside a project which will be then deployed to production as Ready-to-explore Dataset for end users to explore and get insights.

The syntax of Dataset includes 4 main components

  • Dataset metadata: dataset labels, descriptions, owners
  • Data Source reference: users' exploration activities will
  • Data models included
  • Relationship

Dataset syntax

import 'path/to/model_a' {model_a}
import 'path/to/model_b' {model_b}
Dataset dataset_name {
label: 'Dataset Label'
description: "Dataset description here"
data_source_name: 'data_source_name'
models: [
relationships: [
RelationshipConfig {
// Relationship Config syntax goes here
rel: Relationship {
type: 'many_to_one | one_to_many | one_to_one'
from: ref('model_name','dimension_name')
to: ref('model_name','dimension_name')
active: true | false
direction: 'two_way | one_to_many'

Parameter definition

Parameter nameDescription
importAdd other files to the current dataset file
datasetCreate Dataset
labelSpecifies how the dataset will appear in the Ready-to-explore Dataset
descriptionAdd dataset description
ownerDefine who should be in charge of managing the current dataset
data_source_nameSpecify the database that Holistics will execute the generated query against (in dataset)
relationshipsSpecify relationship and their configuration among added models
modelsSpecify which models will be used in the dataset

Dataset syntax example

import '../models/base-model/users.model.aml' { users }
import '../models/base-model/orders.model.aml' { orders }
Dataset raw_ecommerce {
label: 'Raw Ecommerce'
description: "This Dataset is about Ecommerce data nha"
data_source_name: 'demodb'
models: [
relationships: [
RelationshipConfig {
rel: Relationship {
type: 'many_to_one'
from: ref('orders','user_id')
to: ref('users','id')
active: true
direction: 'two_way'

The output