September 3, 2010 at 6:34 am
hj
September 3, 2010 at 12:31 pm
Instead of pulling back all nodes and then checking whether the local name matches, you should just pull back the nodes that do match.
@x.exist('//ConsumerID') = 1
From there, it's simple to see if that node has a specific value.
@x.exist('//ConsumerID[.=11]') = 1
Drew
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 5, 2010 at 10:25 pm
thanks Drew for replying..i got some idea this is exactly i want
IF (@x.exist('//ConsumerID[./text()]') = 1) AND (@x.exist('//RoleConsumerID[./text()]') = 1)
SELECT 'Exists' AS Result
ELSE
SELECT 'Does not exist' AS Result
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy