-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TradaComs26v3 file Charge lines contain =
sign in TCOD TariffDescription
#268
Comments
Further research https://www.ibm.com/docs/en/i/7.3?topic=clause-symbols-used-in-picture shows that X(40) should allow 40 characters from the EBCDIC character set. |
Hi @ianpowell2017 and thanks for your interest in the library. Generally in any of the 3 well known EDI formats the grammar is what makes the allowed character set. The only invalid chracters would be those that are part of the grammar delimiters. And in many cases even those can be escaped so that they can take part of a component value. Keep in mind that generally Tradacoms is the UK style of EDIFact. They are in a sense verry similar with slight differences in conventions about the implicit tags/segments they use for groups messages as well as default chracters they use for delimiters/separators. Are you trying to serialize or deserialize? |
Hi, thanks for the response. |
Since you need the equals sign to be transmitted. Then the issuer must make use of an escape character in order for any parser such as EDI.Net to be able to treat it as part of the value and not part of the syntax. The default escape character for TRADACOMS is the questionmark This would work if send like this out of the box.
Look for example this transmissing in the tests tradacoms.utilitybill.escape.edi it makes use for a preceding You could then try to control the escape character you can do so by setting all special characters (advising the serializer). The following statement sets the escape/release character to var grammar = EdiGrammar.NewTradacoms();
grammar.SetAdvice(
segmentNameDelimiter: '=',
componentDataElementSeparator: ':',
dataElementSeparator: '+',
segmentTerminator: '\'',
releaseCharacter: '@',
reserved: ' ',
decimalMark: null); But still you would not get the whole value if the issuer does not escape the character inside the values. What I am suspecting but cannot verify in resources is that it is a corner case where the parser could be graceful and implicitly escape the Segment name delimiter if and only if
I have made a change to tackle this and will see to release a version. |
You can check out the nuget package for the v2.0.0-beta02 that contains this enhancement. |
Hi, I am a NOOB when it comes to EDI files and so far I have 1.5 weeks of experience!
In a TradaComs file the vendor seems to think its ok to have
=
in the Tariff Description belowCCD=13+4+:Additional Cyclic Re (Balance to be charged=20.26)+:::+++++++++++83000+1000:ZZ:+++83000+83:+A+S+20000+'
Please advise how I should parse this and the presence of the
=
sign in the Tariff Description causing the VATP Vat Rate percentage to be parsed incorrectly.The text was updated successfully, but these errors were encountered: