Hi,
Does anyone know how to import an 834 file, the format used by employers to communicate their employees' health insurance data, into SAS? Below is a screenshot form an example:
INS*Y*18*030*XN*A*E**FT~
REF*OF*152239999~
REF*1L*Blue~
DTP*336*D8*20070101~
NM1*IL*1*BLUTH*LUCILLE****34*152239999~
N3*224 N DES PLAINES*6TH FLOOR~
N4*CHICAGO*IL*60661*USA~
DMG*D8*19720121*F*M~
HD*030**VIS**EMP~
DTP*348*D8*20111016~
INS*N*19*030*XN*A*E***N*N~
REF*OF*152239999~
REF*1L*Blue~
DTP*357*D8*20111015~
NM1*IL*1*BLUTH*BUSTER~
N3*224 N DES PLAINES*6TH FLOOR~
N4*CHICAGO*IL*60661*USA~
DMG*D**19911015*M-HD*030**VIS~
DTP*348*D8*20110101~
DTP*349*D8*20111015~
Here is a crosswalk of some of the codes:
INS*Y | Member Level Detail |
REF*OF | Subscriber Number |
REF*1L | Group Sub-location Division (GSD) |
DTP*336 | Hire date |
NMI | Employee Name |
N3 | Employee Street Address |
N4 | Employee City, State, Zip, Country |
DMG | Member Demographics |
HD | Coverage Data |
DTP*348 | Coverage Dates |
DTP*349 | Coverage End Date |
INS*N | Dependent |
Does anyone have any suggestions?
thanks,
Diane
An 834 transaction is a specialized X12 format for EDI. Usually, specialized translation software is used. I'll Google it, but I don't know if SAS offers this type of translation.
Jim
I turned up the below. I see that he mentions third party software.
Jim
Here's a paper that discusses SAS and the 837 transaction. Perhaps you could do something similar for the 834, but as I mentioned usually specialized software is employed to do this.
https://support.sas.com/resources/papers/proceedings13/300-2013.pdf
Google some more, but my quick Googling didn't turn up anything that would indicate that SAS has a package to do this.
Jim
Thanks for checking. I was hoping that someone had written code for it. It's worth asking.
I'll take a look at the paper.
Diane
Very rough idea of how you can get started - my coding for this kind of stuff is getting too rusty.
data have;
infile cards DSD dlm="*";
input one $ two$ @@;
if one="INS" and two = "Y" then do;
input @1 var1 $ VAR2 $ VAR3 $ (VAR4-VAR9) ($)
/ (var10-vAR12) ($)
/ (var13-var15) ($)
/ (var16-vAR19) ($)
/ (var20-VAR29) ($);
end;
ELSE IF ONE = "INS" & TWO = "N" THEN DO;
input @1 var1 $ VAR2 $ VAR3 $ (VAR4-VAR10) ($)
/ (var10-vAR12) ($)
/ (var13-var15) ($)
/ (var16-vAR19) ($)
/ (var20-VAR25) ($);
END;
cards;
INS*Y*18*030*XN*A*E**FT~
REF*OF*152239999~
REF*1L*Blue~
DTP*336*D8*20070101~
NM1*IL*1*BLUTH*LUCILLE****34*152239999~
;;;;
run;
proc print data=have;run;
Hi,
Yes, there can be multiple dependents and a spouse or not. Sometimes there's a SSN and sometimes not.
My goal is to compare what is in the weekly 834 and a report from the enrollment system. Sadly, the 834 enrollment file is manually entered so we want to check the data entry. This is only for the enrollment file.
thanks for responding.
Diane
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.