SELECT
    A.PATID AS "OneFlorida Patient ID",
    A.PATNT_KEY AS "Patient Key",
    B.IDENT_ID AS "MRN (UF)",
    C.IDENT_ID AS "MRN (Jax)",
    D.IDENT_ID AS "MRN (Pathology)"
FROM
    [DWS_PCORNET].[pcnv5].[PATIENT_MAPPING] AS A
    LEFT OUTER JOIN [DWS_PROD].[dbo].[ALL_PATIENT_IDENTITIES] AS B ON A.PATNT_KEY = B.PATNT_KEY
    AND B.ident_id_type = 101
    AND B.LOOKUP_IND = 'Y'
    LEFT OUTER JOIN [DWS_PROD].[dbo].[ALL_PATIENT_IDENTITIES] AS C ON A.PATNT_KEY = C.PATNT_KEY
    AND C.ident_id_type = 110
    AND C.LOOKUP_IND = 'Y'
    LEFT OUTER JOIN [DWS_PROD].[dbo].[ALL_PATIENT_IDENTITIES] AS D ON A.PATNT_KEY = D.PATNT_KEY
    AND D.ident_id_type = 99
    AND D.LOOKUP_IND = 'Y'
WHERE
    {PYTHON_VARIABLE: IDTypeSQL} IN ({PYTHON_VARIABLE: IDTypeValues})