
* PROGRAM NAME: PBP_IMPORT_PARTD_CMS.SAS;
* DESCRIPTION:  IMPORT THE INDIVIDUAL PBP TABLES AND MERGE TOGETHER;
  

DATA PBP_MRX;
  SET PBP.PBPMRX(KEEP=
  QID
  HPLAN
  MRX_DRUG_BEN_YN
  MRX_BENEFIT_TYPE
  MRX_ALT_COV_LMT_YN
  MRX_ALT_COV_LMT_AMT
  MRX_ALT_DED_CHARGE
  MRX_ALT_DED_AMOUNT
  MRX_AE_CSTSHR_APPLY
  MRX_ALT_PRE_ICL_COST_SHARE
  MRX_ALT_GAP_COVG_YN
  MRX_AE_OOPTCS_APPLY
  MRX_ALT_CSTSHR_POST_OOPT
  MRX_ALT_DED_TYPE_YN
  MRX_ALT_NO_DED_TIER
  MRX_ALT_DED_TIER_CSTSHR_YN
  MRX_ALT_GEN_COINS_PCT
  MRX_ALT_GEN_COPAY_AMT
  MRX_ALT_GEN_CSTSHR_STRUCT
  MRX_FIRST_FILL);
  IF PUT(HPLAN,$TYPEF.) NE 'NO';
RUN;

DATA PBP_MRX_P;
  SET PBP.PBPMRX_P(KEEP=
  QID
  HPLAN
  MRX_TIER_POST_COST_STRUCT
  MRX_TIER_POST_ID
  MRX_TIER_POST_TYPE_ID
  MRX_TIER_POST_COPAY_AMT
  MRX_TIER_POST_COINS_PCT);
  IF PUT(HPLAN,$TYPEF.) NE 'NO';
RUN;

DATA PBP_MRX_TIER;
  SET PBP.PBPMRX_T(KEEP=
  QID
  HPLAN
  MRX_TIER_ID
  MRX_TIER_TYPE_ID
  MRX_TIER_CSTSHR_STRUCT_TYPE
  MRX_TIER_RSPFD_COPAY_1M
  MRX_TIER_RSTD_COPAY_1M
  MRX_TIER_RSSTD_COPAY_1M
  MRX_TIER_OONP_COPAY_1M
  MRX_TIER_RSPFD_COINS_1M
  MRX_TIER_RSTD_COINS_1M
  MRX_TIER_RSSTD_COINS_1M
  MRX_TIER_OONP_COINS_1M
  MRX_TIER_GAP_COST_SHARE
  MRX_TIER_INCLUDES);
  IF PUT(HPLAN,$TYPEF.) NE 'NO';
RUN;

