Previous Next

Thread: input format help needed

Last post 07-21-2008 7:08 PM by jmough. 4 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (5 items)

Sort Posts:

  • 07-18-2008, 5:48 PM

    • jmough
    • Not Ranked
    • Joined on 07-18-2008, 5:43 PM
    • Posts 3

    input format help needed

    I'm attempting to parse some HL7 files into a CSV, SQL, or any other format that I can then use to import to MS Access for analysis.  HL7 is a text file using vertical pipes ("|") to delimit data.

    Any suggestions will be appreciated.  I've been trying HAPI, MIRTH, and a couple of commercial packages but I'm not impressed with the results (If you want something right, do it yourself)

     

    Thanks

  • 07-20-2008, 6:02 PM In reply to

    Re: input format help needed

     I am fairly new to LogParser but you should be able to do do that using -o:tsv -oSeparator:"|" and then pushing that INTO some other output sink.

  • 07-21-2008, 3:10 AM In reply to

    • yellowdog.dave
    • Top 50 Contributor
    • Joined on 07-18-2008, 3:17 AM
    • Johannesburg, South Africa
    • Posts 83

    Re: input format help needed

    Hi There, 

    I am not familiar with HL7 logs, but if they are just a text file with | delimited data, then you can use logparser to pump it straight into your Access database. You can also let logparser determine your data types from the data, so that you will not need to do a data import into Access. Look at the"TSV input Format Parameters" in the logparser.chm help file to get the specifics for the dtLines (data type lines). There are also numerous other parameters which I find useful when parsing non-standard type data. The header line is also very useful to give your elements meaningful names when dealing with each field. The default values of these parameters are generally good to go.

    The following example will pump | delimited data straight into and Access database table.

    LogParser  -i:tsv -iseparator:"|" "select * INTO MyTable FROM sample.hl7"  -o:SQL -oConnString:"Driver={Microsoft Access Driver (*.mdb)};Dbq=C:\MyDB\MyDB.mdb;Uid=MyUsername;Pwd=MyPassword" 

    A quick observation for you; why not use logparser to directly analyse the HL7 data? When you get more familiar and start seeing the speed of the processing and start looking into the advanced features in the product, you will find the file checkpointing, multiplexing files, charting of output, creation of web pages for reporting etc etc very useful. This literally obviates the intermediate step of having to transform data from one format to another. 

    Good luck and enjoy. 

    Cheers, Dave 

    Yes, dear
  • 07-21-2008, 7:07 PM In reply to

    • jmough
    • Not Ranked
    • Joined on 07-18-2008, 5:43 PM
    • Posts 3

    Re: input format help needed

    many thanks.

  • 07-21-2008, 7:08 PM In reply to

    • jmough
    • Not Ranked
    • Joined on 07-18-2008, 5:43 PM
    • Posts 3

    Re: input format help needed

    thanks

Page 1 of 1 (5 items)
Page view counter