/*************************** COMMENTS ********************************/ /* */ /* IF YOU RECEIVED HOSPICE FILES BEFORE JANUARY 2006 THEN YOU WILL */ /* NEED A DIFFERENT INPUT STATEMENT. PLEASE CONTACT ANGELA MEEKINS VIA */ /* E-MAIL MEEKINSA@IMSWEB.COM AND AN INPUT STATEMENT WILL BE SENT TO YOU.*/ /* */ /*************************************************************************/ /* */ /* For cancer files, Patient Identifier is @03 REGCASE $char10. */ /* For non-cancer files, Patient Identifier is @03 HICBIC $char11. */ /* */ /*************************************************************************/ /*************** IMPORTANT PROGRAMING NOTES **************************/ /* TO IDENTIFY CLAIMS PER PATIENT */ /* */ /* The REGCASE/HICBIC, daily date in column 43 and the link number in */ /* column 378 should be used to identify all the records for each */ /* claim per patient. All are needed to identify a claim. */ /*************************************************************************/ /*************************************************************************/ /* TO CALCULATE COSTS PER PATIENT */ /* */ /* When calculating costs per patient you will need to use the payment */ /* amount variable in column 136. This variable is present only when */ /* record count (column 392) is equal to 1. This is to help eliminate */ /* duplicate counting. */ /*************************************************************************/ *filename inout '/directory/hspsaf98.txt'; /*reading in an un-zipped file*/ filename inout pipe 'gunzip -c /directory/hspsaf98.txt.gz'; /*reading in a zipped file*/ options nocenter validvarname=upcase; data hospice; infile inout lrecl=395 recfm=f missover pad; input @1 ric_cd $char1. @2 rec_lvl $char1. @3 regcase $char10. /*@3 HICBIC $char11.*/ /*Non Cancer ID*/ @14 bic $char2. @16 state_cd $char2. @18 cnty_cd $char3. @21 st_sgmt $char1. @22 bene_zip $char9. /**********Special permission required**************/ @31 sex $char1. @32 race $char1. @41 ms_cd $char2. @43 daily_dtm $char2. /*use daily date and link number to identify a claim for each patient*/ @45 daily_dtd $char2. @47 daily_dty $char4. @51 from_dtm $char2. @53 from_dtd $char2. @55 from_dty $char4. @59 thru_dtm $char2. @61 thru_dtd $char2. @63 thru_dty $char4. @67 cwfloccd $char1. @68 acrt_dtm $char2. @70 acrt_dtd $char2. @72 acrt_dty $char4. @76 acrtn_nm 4. @80 disp_cd $char2. @82 fi_num $char5. @87 rcpt_dtm $char2. @89 rcpt_dtd $char2. @91 rcpt_dty $char4. @95 aprv_dtm $char2. @97 aprv_dtd $char2. @99 aprv_dty $char4. @103 schl_dtm $char2. @105 schl_dtd $char2. @107 schl_dty $char4. @111 provider $char6. @117 query_cd $char1. @118 fac_type $char1. @119 typesrvc $char1. @120 freq_cd $char1. @121 pe_ric $char1. @122 trans_cd $char1. @136 pmt_amt 15.2 @151 tot_chrg 15.2 @203 authrztn $char18. @221 prpay_cd $char1. @222 prpayamt 15.2 @237 actioncd $char1. @238 cancelcd $char1. @239 at_upin $char6. @245 stus_cd $char2. @247 util_day 4. @251 hspstrtm $char2. @253 hspstrtd $char2. @255 hspstrty $char4. @259 exhs_dtm $char2. @261 exhs_dtd $char2. @263 exhs_dty $char4. @267 hospcprd $char1. @268 hsrevcnt $char3. @271 center $char4. @275 hcpcs $char5. @280 mf1 $char2. @282 mf2 $char2. @284 unit 8. @292 rate 15.2 @307 charge 15.2 @322 ded $char1. @323 dgn_cd1 $char5. @328 dgn_cd2 $char5. @333 dgn_cd3 $char5. @338 dgn_cd4 $char5. @343 dgn_cd5 $char5. @348 dgn_cd6 $char5. @353 dgn_cd7 $char5. @358 dgn_cd8 $char5. @363 dgn_cd9 $char5. @368 dgn_cd10 $char5. @373 year $char4. @377 saf_ind $char1. @378 link_num $char10. /*use daily date and link number to identify a claim for each patient*/ @388 tot_seg $char2. @390 seg_num $char2. @392 rec_count $char3. @395 filler $char1. ; label rec_lvl = '2 - Near-line rec. version' ric_cd = '3 - NCH Near-line RIC' bic = '8 - BIC' state_cd = '10 - State code' cnty_cd = '36 - County code' st_sgmt = '9 - St. segment near-line code' bene_zip = '43 - Zip code (Special Permission Required)' sex = '44 - Sex code' race = '45 - Race code' ms_cd = '47 - Medicare Status code' daily_dty = '20 - Year of Daily processing' daily_dtm = '20 - Month of Daily processing' daily_dtd = '20 - Day of Daily processing' from_dty = '11 - Year of From date' from_dtm = '11 - Month of From date' from_dtd = '11 - Day of From date' thru_dty = '12 - Year of Thru date' thru_dtm = '12 - Month of Thru date' thru_dtd = '12 - Day of Thru date' cwfloccd = '51 - CWF location' acrt_dty = '14 - Year of Accretion' acrt_dtm = '14 - Month of Accretion' acrt_dtd = '14 - Day of Accretion' acrtn_nm = '15 - Accretion number' disp_cd = '33 - Claim disposition code' fi_num = '40 - Ficarr id number' rcpt_dty = '37 - Year of receipt date' rcpt_dtm = '37 - Month of receipt date' rcpt_dtd = '37 - Day of receipt date' aprv_dty = '61 - Year of processing date' aprv_dtm = '61 - Month of processing date' aprv_dtd = '61 - Day of processing date' schl_dty = '38 - Year of payment date' schl_dtm = '38 - Month of payment date' schl_dtd = '38 - Day of payment date' provider = '19 - Provider number' query_cd = '18 - Claim query' fac_type = '28 - Claim facility type' typesrvc = '29 - Classification type code' freq_cd = '30 - Claim frequency code' pe_ric = '26 - Payment and edit ric' trans_cd = '27 - Claim transaction' pmt_amt = '56 - Claim payment amount' authrztn = '82 - Claims Treatment Authorization number' tot_chrg = '91 - Claim total charge amt.' prpay_cd = '58 - Primary payer code' prpayamt = '57 - Primary payer payment amt.' actioncd = '60 - Claim action' cancelcd = '59 - Cancel reason' at_upin = '64 - Claim attending physician UPIN' stus_cd = '87 - Patient discharge status code' util_day = '110 - Utilization days count' hspstrty = '107 - Year of start date' hspstrtm = '107 - Month of start date' hspstrtd = '107 - Day of start date' exhs_dty = '108 - Year of exhausted' exhs_dtm = '108 - Month of exhausted' exhs_dtd = '108 - Day of exhausted' hospcprd = '111 - Hospice period count' hsrevcnt = '24 - Revenue center code count' center = '150 - Revenue center code' mf1 = '158 - Initial modifier code' mf2 = '159 - Second modifier code' hcpcs = '157 - Hcpcs code' unit = '170 - Revenue center unit count' rate = '171 - Revenue center rate amount' charge = '183 - Revenue center total amount' ded = '185 - Deductible coinsurance code' dgn_cd1 = '131 - ICD-9-CM code #1' dgn_cd2 = '131 - ICD-9-CM code #2' dgn_cd3 = '131 - ICD-9-CM code #3' dgn_cd4 = '131 - ICD-9-CM code #4' dgn_cd5 = '131 - ICD-9-CM code #5' dgn_cd6 = '131 - ICD-9-CM code #6' dgn_cd7 = '131 - ICD-9-CM code #7' dgn_cd8 = '131 - ICD-9-CM code #8' dgn_cd9 = '131 - ICD-9-CM code #9' dgn_cd10 = '131 - ICD-9-CM code #10' year = 'Claim Year' saf_ind = 'SAF indicator' link_num = 'Link Number' tot_seg = 'Total Segment Count' seg_num = 'Segment Number' rec_count = 'Record Count for Claim' ; run; proc contents data=hospice position; run;