× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



There has to be something else adrift with your XML document. I just tried to process this:

<Chars>
<apos>&apos;</apos>
<amp>&amp;</amp>
<lt>&lt;</lt>
<gt>&gt;</gt>
<quot>&quot;</quot>
</Chars>

And it works perfectly.

Here's the code if you want to play with it yourself. If you run this and still have an error then perhaps you are missing a PTF or something.

dcl-ds Chars;
apos char(1);
amp char(1);
lt char(1);
gt char(1);
quot char(1);
end-ds;

dcl-s wait char(11) Inz('Press Enter');

dcl-s XMLSource varchar(256)
Inz('/Home/Paris/xmltest.xml');

xml-into Chars %xml(XMLSource:
'case=any doc=file');

Dsply ('Chars = [' + Chars + ']') ' ' wait;

*inlr = *on;


Jon Paris

www.partner400.com
www.SystemiDeveloper.com

On Apr 2, 2019, at 2:19 AM, Nirvan Chakravarthi <nirchak88@xxxxxxxxx> wrote:

Thanks for the quick response Vernon!

But i have the character entities (&amp;) in below tag not just &) then why
it is giving me error i don't know. If it is giving error for characters
entities also why it is not giving error for *&lt;*

Also if you see my tag below (at end) i have not used character entities (
*&apos;* , *&quot;*) for single quote and double quote but it is working.
The only problem in below tag is &amp if i remove all working fine.

<packslipMessage>*Character@ .°¢⠢&amp;èé⠬-á&lt; " 'Test>
</packslipMessage>
--

Regards by

*Nirvan Chakravarthi | Software Engineer*

*Manhattan Associates, Inc.*

*http://www.manh.com <http://www.manh.com/>*


On Mon, Apr 1, 2019 at 7:42 PM Vernon Hamberg <vhamberg@xxxxxxxxxxxxxxx>
wrote:

In addition, when you get the error, I believe you might have the
position where the error occurred somewhere in the message text or
second-level text.

Vern

On 4/1/2019 9:37 AM, Vernon Hamberg wrote:
You can google for "XML entities" - there are 5 - quot, amp, apos, lt,
and gt - they are rendered in a document in the format &name;

These characters all have special meaning in XML, so they cannot be on
their own in a string, then need either to be rendered using the
entity or in Unicode code point - for example, quot is U+0022, so you
put &# before 0022 and ; after it - see one of the articles in that
google search for more information.

HTH
Vern

On 4/1/2019 6:52 AM, Nirvan Chakravarthi wrote:
Hi All,

Could you please help me on this ?

I am getting parsing error ' The parser found an invalid character in
element content. ' when i am trying to parse below Tag and when i
manually
remove *&amp; *it is working fine. *&amp; *and* &lt; *are valid right
? i
believe having only & is the problem.

<packslipMessage>*Character@ .°¢⠢&amp;èé⠬-á&lt; "'Test*
</packslipMessage>

it is <?xml version="1.0" encoding="UTF-8"?>

it would be great if someone tell me that what are special characters
are
illegal so that i can tell my host system not to send those characters.


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related questions.

Help support midrange.com by shopping at amazon.com with our affiliate link: https://amazon.midrange.com


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.