provider_source_value
SUS Outpatient Provider
-
Value copied from
ConsultantCode -
ConsultantCodeA unique code identifying a care professional CONSULTANT CODE
with counts as (
select
ConsultantCode,
MainSpecialtyCode,
count(*) as SpecialtyFrequency,
row_number() over (partition by ConsultantCode order by count(*) desc, MainSpecialtyCode
) rnk
from (
select
ConsultantCode,
MainSpecialtyCode
from omop_staging.sus_OP
where MainSpecialtyCode is not null
and ConsultantCode is not null
) grouped
group by ConsultantCode, MainSpecialtyCode
)
select
ConsultantCode,
MainSpecialtyCode
from counts
where rnk = 1
order by
ConsultantCode,
MainSpecialtyCode
Comment or raise an issue for this mapping.
SUS Inpatient Provider
-
Value copied from
ConsultantCode -
ConsultantCodeA unique code identifying a care professional CONSULTANT CODE
with counts as (
select
ConsultantCode,
MainSpecialtyCode,
count(*) as SpecialtyFrequency,
row_number() over (partition by ConsultantCode order by count(*) desc,
MainSpecialtyCode
)
rnk
from
(
select
ConsultantCode,
MainSpecialtyCode
from omop_staging.sus_APC
where MainSpecialtyCode is not null
and ConsultantCode is not null
) grouped
group by ConsultantCode, MainSpecialtyCode
)
select
ConsultantCode,
MainSpecialtyCode
from counts
where rnk = 1
order by
ConsultantCode,
MainSpecialtyCode
Comment or raise an issue for this mapping.
SACT Provider
-
Value copied from
Consultant_GMC_Code -
Consultant_GMC_CodeA unique code identifying a care professional CONSULTANT GMC CODE
select distinct
Consultant_GMC_Code,
Consultant_Specialty_Code
from omop_staging.sact_staging
Comment or raise an issue for this mapping.
RTDS Provider
-
Value copied from
DoctorId -
DoctorIdThis GENERAL MEDICAL PRACTITIONER works within the General Medical Practitioner Practice with which the PATIENT is registered. GENERAL MEDICAL PRACTITIONER (SPECIFIED)
select distinct
DoctorId
from omop_staging.RTDS_1_Demographics
where DoctorId is not null