Menu

#12 Conversion from Flat File to XML - some values in wrong fields...

2.0
closed
None
2019-12-03
2019-10-30
No

Hi
I took a flat file of an ORDERS D.01B message and converted it to XML.

The majority of value appear in the correct fields as far as I can determine. there are two in the attached XML that are not (they are repeats of the same segment, so bug is the same).

<s_imd>
<d_7077>F</d_7077>
<c_c273>
<d_3055>PRODUCT 1</d_3055>
</c_c273>
</s_imd>

As far as I can discern, the value PRODUCT1 should be in the field <d_7088>, <d_3055> is actually the "Code list responsible agency code" field and is maxLen 3.</d_3055></d_7088>

2 Attachments

Discussion

  • Brian Arthern

    Brian Arthern - 2019-10-30

    Hi
    I've done some experimenting and I believe the bug is that the parser is not factoring in that there is actually a field between the + and the :

    This is the line - IMD+F++:::PRODUCT 1'

    If I add a value between + and : like so

    IMD+F++A:::PRODUCT 1'

    Then it aligns correctly:

    <s_imd>
    <d_7077>F</d_7077>
    <c_c273>
    <d_7009>A</d_7009>
    <d_7008>PRODUCT 1</d_7008>
    </c_c273>
    </s_imd>

     
  • Matthias Fricke

    Matthias Fricke - 2019-10-30
    • status: open --> accepted
    • assigned_to: Matthias Fricke
     
  • Matthias Fricke

    Matthias Fricke - 2019-10-30

    Hi Brian,

    thanks for your input.

    I am very busy these days with project work (my job).

    So it might take some time for me to have a look into the problems.

    Did you use the downloads? Our did you build from git / maven?

    The git/maven stuff is more current (though not completly tested)
    https://sourceforge.net/p/edifactconverter/code/

    Best Matthias

     
    • Brian Arthern

      Brian Arthern - 2019-10-30

      Hi Matthias,

      Fully understand this is a side-line, not an issue :-)
      I did use the latest snapshot, but will download and try using the code. I will let you know if the issue is already resolved in the latest code base.

      cheers
      Brian

       
    • Brian Arthern

      Brian Arthern - 2019-10-30

      Hi Matthias,

      I tried running with the latest code-set but encountered the same defect. Just an FYI.

      cheers
      Brian

       
  • Matthias Fricke

    Matthias Fricke - 2019-11-08

    Hi Brian,

    I think it might be fixed.

    I have attached the converter in its latest state.

    Can you have a look?

    Thanks

    Matthias

     
    👍
    1
    • Brian Arthern

      Brian Arthern - 2019-11-12

      Hi Matthias,

      You are the man - it is fixed :-)

      cheers
      Brian

       
  • Matthias Fricke

    Matthias Fricke - 2019-12-03
    • status: accepted --> closed
     

Log in to post a comment.

MongoDB Logo MongoDB