-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstatus_hours.view.lkml
55 lines (49 loc) · 1.13 KB
/
status_hours.view.lkml
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
view: status_hours {
sql_table_name: uptime.status_hours ;;
dimension_group: date {
description: "timestamp of the data collection"
type: time
timeframes: [
raw,
time,
hour,
date,
week,
month,
quarter,
year
]
sql: ${TABLE}."date" ;;
drill_fields: [uptime,region,date_date]
}
dimension: compound_primary_key {
primary_key: yes
hidden: yes
sql: ${TABLE}."date" || ${TABLE}."region" ;;
}
dimension: region {
description: "Name of the region"
type: string
sql: ${TABLE}."region" ;;
drill_fields: [uptime,region,date_date]
}
dimension: uptime {
description: "Uptime percentage"
type: number
sql: ${TABLE}."value" ;;
value_format_name: percent_1
drill_fields: [uptime,region,date_date]
}
measure: count {
description: "Number of distinct objects returned in query"
type: count
drill_fields: [uptime,region,date_date]
}
measure: uptime_sum{
description: "Sum of the uptime"
type: sum
sql: ${TABLE}."value" ;;
value_format_name: percent_1
drill_fields: [uptime,region,date_date]
}
}