Is there any good Java X12 parser in Java?

Is there any good Java X12 parser in Java that can handle the Walmart 810 specification?

EDI Example:

ISA*00*          *00*          *16*102096559TEST  *14*PARTNERTEST    *071214*1406*U*00040*810000263*1*T*>
  GS*IN*102096559TEST*PARTNER*20071214*1406*810000263*X*004010
    ST*810*0001
      BIG*20050205*6463367*20050202*3376103367
      REF*IA*123456170*X5T
      REF*DP*00017
      REF*MR*0020
      N1*SU*SUPPLIER NAME
      N1*ST*WAL-MART 100*UL*0078742000992
        N3*406 SOUTH WALTON BLVD
        N4*BENTONVILLE*AR*72712 
      ITD*05*15*****45
      DTM*011*20050205
      FOB*CC
      IT1**1080*EA*3.61**IN*001719653*UP*022108955228*UK*            00221089552284       
        PID*F****ITEM DESCRIPTION
        SAC*A*I410***2350*******02
      TDS*387530
      CAD*T***RDWT*ROADWAY**BM*123456789
      ISS*1080*EA*100*LB
      CTT*1
    SE*19*0001
  GE*1*810000263
IEA*1*810000263
+5
source share
5 answers

Try this, edireader

The analyzer distinguishes between the ANSI X.12 and EDIFACT EDI standards by checking and uses the factory pattern to construct the appropriate parser subclass.

The parser can be integrated into your Java application in the same way as an XML parser, avoiding the file and proprietary interfaces often used with regular EDI translators.

+6
source

Try using smooks . On the page:

Smooks - XML XML (CSV, EDI, Java ..) Java.

+3

, Oakland Data Transformer. Java, Eclipse Java API Apache Camel, Mule ESB OSGi Blueprint. XML, , Java .

Oakland Software , X12 4010 810, .

0

you can try bots: http://bots.sourceforge.net is not java, but python. this is not a "library", but an application. x12 pens OK, including 810. You can transfer it to the desired format (xml, csv, flat file)

0
source

We can use apache camel, camel is a very easy and extensible solution to this,

This will give json objects, after which we can parse the json objects, then get the values.

XmlJsonDataFormat xmlJsonFormat = new XmlJsonDataFormat();
        xmlJsonFormat.setEncoding("UTF-8");
        xmlJsonFormat.setForceTopLevelObject(true);
        xmlJsonFormat.setTrimSpaces(true);
        xmlJsonFormat.setRootName("newRoot");
        xmlJsonFormat.setSkipNamespaces(true);
        xmlJsonFormat.setRemoveNamespacePrefixes(true);
    //  xmlJsonFormat.setExpandableProperties(Arrays.asList("d", "e"));

          from("file:sftpdata/x12files")
            .log("Before unmarshal with SmooksDataFormat:").log("${body}")
            .unmarshal(new SmooksDataFormat("smooks-config1.xml"))
            .log("After unmarshal with SmooksDataFormat:").log("${body}")
           .marshal(xmlJsonFormat)
             .log("After marshalling with Json library:").log("${body}")
             .process(new X12Processor()).log("X12 file processed")
            .to("mock:result");
0
source

All Articles