how can I say in xpath, get me all the nodes in list 2 that are not in list 1 using k as key ?

G

G. Tarazi

Hi



I am modifying an xslt manually (for InfoPath), and I am trying to figure out how to do the following:



I have a document with 2 lists of nodes, List A and List B, both have the same structure, and both have a node that is used as a key




List1

k = 1

a = "abc"

b = "abc"



k = 2

a = "cxd"

b = "cxd"



List 2

k = 1

a = "abc"

b = "abc"



k = 3

a = "cfg"

b = "cfg"





how can I say in xpath, get me all the nodes in list 2 that are not in list 1 using k as key



Thanks
 
G

G. Tarazi

Actually I found the answer my self, it can happen with 2 queries, the first one to perform the filter (for each) and the second one just a normal if statement with the count command to make sure the count of the similar elements is 0

"G. Tarazi" <Tarazi (at) LiveTechnologies.ca> wrote in message
Hi



I am modifying an xslt manually (for InfoPath), and I am trying to figure out how to do the following:



I have a document with 2 lists of nodes, List A and List B, both have the same structure, and both have a node that is used as a key




List1

k = 1

a = "abc"

b = "abc"



k = 2

a = "cxd"

b = "cxd"



List 2

k = 1

a = "abc"

b = "abc"



k = 3

a = "cfg"

b = "cfg"





how can I say in xpath, get me all the nodes in list 2 that are not in list 1 using k as key



Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top