BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hello - I am coding (from scratch) a parsing program that will extract health care claims data from the ANSI ASC X12N 837 Health Care Claims (837) transaction layout. Due to the program complexity, I've been searching for a sample SAS program that has done this before - but haven't found one yet. Does anyone have any suggestions about where I could locate such a program?

Thanks.
1 REPLY 1
Cynthia_sas
SAS Super FREQ
Hi, Chris:
In looking at this site:
http://files.medi-cal.ca.gov/pubsdoco/publications/Masters-other/4010/837_v4010A1_data_specs_cg01.pd...
it seems to me that your data might fall into a complicated format, where you have to read a record identifier and then write a separate INPUT statement for each different kind of record.


The PDF that describes your record layout does say that it is a hierarchical file and refers to the possible repetition of records as "LOOPS". It is possible to read a hierarchical file with SAS. However, to do it will involve an advanced use of the INPUT statement and possibly include the use of the trailing @ sign to hold each record for further parsing after you make the decision (with an IF statement) about what the record format is. You may also need to use the RETAIN statement to retain or keep information from different records in the hierarchy, because information found on a higher level record is not repeated on a lower level record (according to the PDF).

Tech Support DOES have a sample of reading a simple hierarchical file. Their program creates a little sample file with a few record types as step 1 and then their Step 2 program parses the hierarchical file. The URL for the sample program is here:
http://support.sas.com/ctx/samples/index.jsp?sid=96&tab=about


If you still feel that you need help with the syntax, after reviewing the sample, your best bet with this kind of problem is to contact Tech Support. It will be easier for them to help you with the program if you can provide a sample of what the data -actually- looks like. Here's the link with the ways to contact Tech Support.
http://support.sas.com/techsup/contact/index.html

Good luck,
cynthia

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 2028 views
  • 0 likes
  • 2 in conversation