Link to home
Start Free TrialLog in
Avatar of pprasadravi
pprasadravi

asked on

xmlnode no child nodes

Hi
here is my xml document and want to get the Persons node with out Address node.

i mention the output format.
Can anybody have clue,please help me.

Ex:

<Persons>
      <Person>
            <FirstName></FirstName>
            <LastName></LastName>
            <Address>
                  <Line1></Line1>
                  <Line2></Line2>
            </Address>
            </Person>
            <Person>
            <FirstName></FirstName>
            <LastName></LastName>
            <Address>
                  <Line1></Line1>
                  <Line2></Line2>
            </Address>
            </Person>
            <Person>
            <FirstName></FirstName>
            <LastName></LastName>
            <Address>
                  <Line1></Line1>
                  <Line2></Line2>
            </Address>
            </Person>
</Persons>

OuPut :

<Persons>
      <Person>
            <FirstName></FirstName>
            <LastName></LastName>
            
            </Person>
            <Person>
            <FirstName></FirstName>
            <LastName></LastName>
            
            </Person>
            <Person>
            <FirstName></FirstName>
            <LastName></LastName>
            
            </Person>
</Persons>
ASKER CERTIFIED SOLUTION
Avatar of ramazanyich
ramazanyich
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of pprasadravi
pprasadravi

ASKER

can we get the same with xpath query without using xsl.