1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# A happy-path sample exercising most of the YAML surface Holocron supports:
# enums; typed columns with defaults, NULL handling, and constraints; primary
# keys (named and anonymous); indexes (unique, partial via `where`, custom
# `using`); views with multiple joins, raw WHERE/ORDER BY/LIMIT, and
# per-column filterable/searchable flags.
#
# Run: cargo run -- samples/full_features.yml
types:
- name: priority
enum:
tables:
- name: users
if_not_exists: true
columns:
user_id:
username:
email:
bio:
created_at:
primary_key:
indexes:
-
-
- name: tasks
columns:
task_id:
owner_id:
title:
body:
priority:
created_at:
done:
primary_key:
indexes:
-
views:
- name: open_tasks
or_replace: true
from:
join:
- table: users
as: u
type: LEFT
on: "u.user_id = t.owner_id"
select:
-
-
-
-
-
-
where: "t.done = false"
order_by: "t.created_at DESC"
limit: 100