Add new mapping tables
This commit is contained in:
parent
2aa8a4c278
commit
bbc565bcf1
6
definitions/sources/MAPPING_DEPARTMENT.sqlx
Normal file
6
definitions/sources/MAPPING_DEPARTMENT.sqlx
Normal file
@ -0,0 +1,6 @@
|
||||
config {
|
||||
type: "declaration",
|
||||
schema: "pphe_five9_raw",
|
||||
name: "MAPPING_DEPARTMENT",
|
||||
description: ""
|
||||
}
|
||||
6
definitions/sources/MAPPING_SKILL_DEP.sqlx
Normal file
6
definitions/sources/MAPPING_SKILL_DEP.sqlx
Normal file
@ -0,0 +1,6 @@
|
||||
config {
|
||||
type: "declaration",
|
||||
schema: "pphe_five9_raw",
|
||||
name: "MAPPING_SKILL_DEP",
|
||||
description: ""
|
||||
}
|
||||
16
definitions/staging/stg_SKILL.sqlx
Normal file
16
definitions/staging/stg_SKILL.sqlx
Normal file
@ -0,0 +1,16 @@
|
||||
config {
|
||||
type: "view",
|
||||
schema: "pphe_five9_stg",
|
||||
tags: ["daily"],
|
||||
description: "All fields that are connected to the SKILL"
|
||||
}
|
||||
|
||||
select s.SKILL,
|
||||
s.SKILL_ID,
|
||||
sd.DEPARTMENT_ID,
|
||||
d.DEPARTMENT,
|
||||
from ${ref("MAPPING_SKILL")} s
|
||||
left join ${ref("MAPPING_SKILL_DEP")} sd
|
||||
on s.SKILL_ID = sd.SKILL_ID
|
||||
left join ${ref("MAPPING_DEPARTMENT")} d
|
||||
on sd.DEPARTMENT_ID = d.DEPARTMENT_ID
|
||||
Loading…
Reference in New Issue
Block a user