Skip to content

Commit

Permalink
build: dbt dev config
Browse files Browse the repository at this point in the history
  • Loading branch information
cbini committed Sep 26, 2024
1 parent 1c9885c commit 267730b
Show file tree
Hide file tree
Showing 12 changed files with 39 additions and 7 deletions.
10 changes: 8 additions & 2 deletions .devcontainer/tpl/.env.tpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
DBT_DEV_POWERSCHOOL_SCHEMA=_dev_powerschool
DBT_DEV_DEANSLIST_SCHEMA=_dev_deanslist
DBT_DEV_CLOUD_STORAGE_URI_BASE=gs://teamster-kippnewark/dagster/kippnewark
DBT_DEV_DEANSLIST_SCHEMA=_dev_deanslist
DBT_DEV_EDPLAN_SCHEMA=_dev_edplan
DBT_DEV_IREADY_SCHEMA=_dev_iready
DBT_DEV_OVERGRAD_SCHEMA=_dev_overgrad
DBT_DEV_PEARSON_SCHEMA=_dev_pearson
DBT_DEV_POWERSCHOOL_SCHEMA=_dev_powerschool
DBT_DEV_RENLEARN_SCHEMA=_dev_renlearn
DBT_DEV_TITAN_SCHEMA=_dev_titan
ADP_SFTP_HOST_IP=op://Data Team/ADP Workforce Now SFTP/ip
ADP_SFTP_PASSWORD=op://Data Team/ADP Workforce Now SFTP/password
ADP_SFTP_USERNAME=op://Data Team/ADP Workforce Now SFTP/username
Expand Down
4 changes: 3 additions & 1 deletion src/dbt/deanslist/package-lock.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
packages:
- package: dbt-labs/dbt_external_tables
version: 0.9.0
sha1_hash: f459fa5ae8276125d72b0ae3ae38baf5847fbb81
- package: dbt-labs/dbt_utils
version: 1.3.0
sha1_hash: 86e37da85bb51f86f1ab00f54df3d63a162424dc
3 changes: 3 additions & 0 deletions src/dbt/deanslist/packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@ packages:
# https://github.com/dbt-labs/dbt-external-tables
- package: dbt-labs/dbt_external_tables
version: 0.9.0
# https://github.com/dbt-labs/dbt-utils
- package: dbt-labs/dbt_utils
version: 1.3.0
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ select
ti_serv_other,
ti_serv_physical,
ti_serv_speech,

row_number() over (
partition by student_number, fiscal_year
order by _dbt_source_relation desc, effective_date desc
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ with
select
*,
row_number() over (
partition by row_hash, staging.fiscal_year order by effective_date asc
partition by row_hash, fiscal_year order by effective_date asc
) as rn_row_year_asc,
from staging
)
Expand All @@ -95,6 +95,7 @@ select
then 'SPED'
end
) as spedlep,

if(
nj_se_parentalconsentobtained in ('N', 'R'),
null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@ select
academic_year,
effective_date,
effective_end_date,

academic_year + 1 as fiscal_year,

nullif(nj_se_parental_consentobtained, 'NULL') as nj_se_parentalconsentobtained,
nullif(special_education, 'NULL') as special_education,
nullif(spedlep, 'NULL') as spedlep,
nullif(special_education_code, 'NULL') as special_education_code,

safe_cast(student_number as int) as student_number,
safe_cast(state_studentnumber as int) as state_studentnumber,
safe_cast(nj_se_delayreason as int) as nj_se_delayreason,
Expand All @@ -20,6 +23,7 @@ select
safe_cast(nj_se_initialiepmeetingdate as date) as nj_se_initialiepmeetingdate,
safe_cast(nj_se_consenttoimplementdate as date) as nj_se_consenttoimplementdate,
safe_cast(row_hash as string) as row_hash,

if(ti_serv_counseling, 'Y', 'N') as ti_serv_counseling,
if(ti_serv_occup, 'Y', 'N') as ti_serv_occup,
if(ti_serv_other, 'Y', 'N') as ti_serv_other,
Expand Down
4 changes: 3 additions & 1 deletion src/dbt/edplan/package-lock.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
packages:
- package: dbt-labs/dbt_external_tables
version: 0.9.0
sha1_hash: f459fa5ae8276125d72b0ae3ae38baf5847fbb81
- package: dbt-labs/dbt_utils
version: 1.3.0
sha1_hash: 86e37da85bb51f86f1ab00f54df3d63a162424dc
3 changes: 3 additions & 0 deletions src/dbt/edplan/packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@ packages:
# https://github.com/dbt-labs/dbt-external-tables
- package: dbt-labs/dbt_external_tables
version: 0.9.0
# https://github.com/dbt-labs/dbt-utils
- package: dbt-labs/dbt_utils
version: 1.3.0
4 changes: 3 additions & 1 deletion src/dbt/overgrad/package-lock.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
packages:
- package: dbt-labs/dbt_external_tables
version: 0.9.0
sha1_hash: f459fa5ae8276125d72b0ae3ae38baf5847fbb81
- package: dbt-labs/dbt_utils
version: 1.3.0
sha1_hash: 86e37da85bb51f86f1ab00f54df3d63a162424dc
3 changes: 3 additions & 0 deletions src/dbt/overgrad/packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@ packages:
# https://github.com/dbt-labs/dbt-external-tables
- package: dbt-labs/dbt_external_tables
version: 0.9.0
# https://github.com/dbt-labs/dbt-utils
- package: dbt-labs/dbt_utils
version: 1.3.0
4 changes: 3 additions & 1 deletion src/dbt/pearson/package-lock.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
packages:
- package: dbt-labs/dbt_external_tables
version: 0.9.0
sha1_hash: f459fa5ae8276125d72b0ae3ae38baf5847fbb81
- package: dbt-labs/dbt_utils
version: 1.3.0
sha1_hash: 86e37da85bb51f86f1ab00f54df3d63a162424dc
3 changes: 3 additions & 0 deletions src/dbt/pearson/packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@ packages:
# https://github.com/dbt-labs/dbt-external-tables
- package: dbt-labs/dbt_external_tables
version: 0.9.0
# https://github.com/dbt-labs/dbt-utils
- package: dbt-labs/dbt_utils
version: 1.3.0

0 comments on commit 267730b

Please sign in to comment.