Hi All,

 

We are having an issue with XSLT parser sample (SimpleXPathAPI.exe).

 

When the XPath query (count(/*[1]/*[7]/*[5]/*[1]/*[3]/*[2]/node()))is
made on the document containing the XML node snippet:

"<para id="para13">

 

 
<italic>Expand one&apos;s cultural knowledge</italic>

 

and institutionalize it so that it can be accessed and incorporated into
the delivery of services. We must attempt to seek out sociocultural
information about the individual patient that will then help us have a
better feel for how to perform an interview or history-what to ask, how
to ask-and how to modify treatment interventions appropriately on the
basis of a <anchor id="p27"/>person&apos;s cultural reality. It is
impossible, and unnecessary, to learn all there is to know about all
cultural subgroups, but clinicians must be aware of the ethnographic
information related to the local community and relevant beliefs and
behaviors of their patients and the patients&apos; families.</para>"

 

The parser is considering the leading 'whitespace' characters as one
node and the total node count as 5 which are,

1.    whitespace before <italic>, 

2.    <italic>

3.    text between <italic> and <anchor>

4.    <anchor>

5.    text after <anchor> till end.

 

As per our requirement the count should be 4 (excluding the (1) above).

 

We request to kindly let us know how to ignore these 'whitespace' nodes
which are 

actually children of 'Text node' types, through Xpath queries since we
do not have the freedom to reload the document in any other
configuration.

 

Regards,

Anand

Reply via email to