File tree Expand file tree Collapse file tree 11 files changed +14
-14
lines changed Expand file tree Collapse file tree 11 files changed +14
-14
lines changed Original file line number Diff line number Diff line change @@ -142,7 +142,7 @@ with eligibility_unpivot as (
142
142
, joined as (
143
143
144
144
select
145
- cast(enrollment_span .desy_sort_key as {{ dbt .type_string () }} ) as patient_id
145
+ cast(enrollment_span .desy_sort_key as {{ dbt .type_string () }} ) as person_id
146
146
, cast(enrollment_span .desy_sort_key as {{ dbt .type_string () }} ) as member_id
147
147
, cast(enrollment_span .desy_sort_key as {{ dbt .type_string () }} ) as subscriber_id
148
148
, case eligibility_unpivot .sex_code
@@ -195,7 +195,7 @@ with eligibility_unpivot as (
195
195
)
196
196
197
197
select
198
- patient_id
198
+ person_id
199
199
, member_id
200
200
, subscriber_id
201
201
, gender
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ with unioned as (
28
28
, member_months as (
29
29
30
30
select distinct
31
- a .patient_id
31
+ a .person_id
32
32
, year_nbr
33
33
, month_nbr
34
34
, a .payer
46
46
c .claim_id
47
47
, c .claim_line_number
48
48
, c .claim_type
49
- , c .patient_id
49
+ , c .person_id
50
50
, c .member_id
51
51
, c .payer
52
52
, c .plan
@@ -192,6 +192,6 @@ select
192
192
, c .ingest_datetime
193
193
from unioned as c
194
194
inner join member_months as mm
195
- on c .patient_id = mm .patient_id
195
+ on c .person_id = mm .person_id
196
196
and extract(year from c .claim_start_date ) = mm .year_nbr
197
197
and extract(month from c .claim_start_date ) = mm .month_nbr
Original file line number Diff line number Diff line change 1
1
select
2
2
cast(null as {{ dbt .type_string () }}) as claim_id
3
3
, cast(null as {{ dbt .type_string () }}) as claim_line_number
4
- , cast(null as {{ dbt .type_string () }}) as patient_id
4
+ , cast(null as {{ dbt .type_string () }}) as person_id
5
5
, cast(null as {{ dbt .type_string () }}) as member_id
6
6
, cast(null as {{ dbt .type_string () }}) as payer
7
7
, cast(null as {{ dbt .type_string () }}) as plan
Original file line number Diff line number Diff line change 26
26
as claim_id
27
27
, cast(l .line_num as integer ) as claim_line_number
28
28
, ' professional' as claim_type
29
- , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as patient_id
29
+ , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as person_id
30
30
, cast(b .desy_sort_key as {{ dbt .type_string () }} ) as member_id
31
31
, cast(' medicare' as {{ dbt .type_string () }} ) as payer
32
32
, cast(' medicare' as {{ dbt .type_string () }} ) as plan
Original file line number Diff line number Diff line change 26
26
as claim_id
27
27
, cast(l .clm_line_num as integer ) as claim_line_number
28
28
, ' professional' as claim_type
29
- , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as patient_id
29
+ , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as person_id
30
30
, cast(b .desy_sort_key as {{ dbt .type_string () }} ) as member_id
31
31
, cast(' medicare' as {{ dbt .type_string () }} ) as payer
32
32
, cast(' medicare' as {{ dbt .type_string () }} ) as plan
Original file line number Diff line number Diff line change 41
41
as claim_id
42
42
, cast(l .clm_line_num as integer ) as claim_line_number
43
43
, ' institutional' as claim_type
44
- , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as patient_id
44
+ , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as person_id
45
45
, cast(b .desy_sort_key as {{ dbt .type_string () }} ) as member_id
46
46
, cast(' medicare' as {{ dbt .type_string () }} ) as payer
47
47
, cast(' medicare' as {{ dbt .type_string () }} ) as plan
Original file line number Diff line number Diff line change 41
41
as claim_id
42
42
, cast(l .clm_line_num as integer ) as claim_line_number
43
43
, ' institutional' as claim_type
44
- , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as patient_id
44
+ , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as person_id
45
45
, cast(b .desy_sort_key as {{ dbt .type_string () }} ) as member_id
46
46
, cast(' medicare' as {{ dbt .type_string () }} ) as payer
47
47
, cast(' medicare' as {{ dbt .type_string () }} ) as plan
Original file line number Diff line number Diff line change 34
34
b .claim_id
35
35
, cast(l .clm_line_num as integer ) as claim_line_number
36
36
, ' institutional' as claim_type
37
- , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as patient_id
37
+ , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as person_id
38
38
, cast(b .desy_sort_key as {{ dbt .type_string () }} ) as member_id
39
39
, cast(' medicare' as {{ dbt .type_string () }} ) as payer
40
40
, cast(' medicare' as {{ dbt .type_string () }} ) as plan
Original file line number Diff line number Diff line change 44
44
as claim_id
45
45
, cast(l .clm_line_num as integer ) as claim_line_number
46
46
, ' institutional' as claim_type
47
- , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as patient_id
47
+ , cast(b .desy_sort_key as {{ dbt .type_string () }} ) as person_id
48
48
, cast(b .desy_sort_key as {{ dbt .type_string () }} ) as member_id
49
49
, cast(' medicare' as {{ dbt .type_string () }} ) as payer
50
50
, cast(' medicare' as {{ dbt .type_string () }} ) as plan
Original file line number Diff line number Diff line change 44
44
b .claim_id
45
45
, cast(l .clm_line_num as integer ) as claim_line_number
46
46
, ' institutional' as claim_type
47
- , cast(b .desy_sort_key as {{ dbt .type_string () }}) as patient_id
47
+ , cast(b .desy_sort_key as {{ dbt .type_string () }}) as person_id
48
48
, cast(b .desy_sort_key as {{ dbt .type_string () }}) as member_id
49
49
, cast(' medicare' as {{ dbt .type_string () }} ) as payer
50
50
, cast(' medicare' as {{ dbt .type_string () }} ) as plan
You can’t perform that action at this time.
0 commit comments