[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

select elements based on value NOT contained in desce

Subject: select elements based on value NOT contained in descendant elements
From: cknell@xxxxxxxxxx
Date: Tue, 17 Jul 2007 15:38:47 -0400
 select elements based on value NOT contained in  desce
Consider this structure:
<ROWSET>
<ROW>
  <NAME/>
  <CREDIT_CARDS>
    <CREDIT_CARD>
       <ISSUER/>
       <NUMBER/>
    </CREDIT_CARD>
    <CREDIT_CARD>
       <ISSUER/>
       <NUMBER/>
    </CREDIT_CARD>
  </CREDIT_CARDS>
</ROW>
</ROWSET>

I need to select the rows who do not have a CREDIT_CARD descendant whose ISSUER descendant contains one of a set of values.

For example, say that I want to select all ROW elements that do not have an ISSUER descendant with one of these values: ABC, MNO, RST


I tried a construct like this, but it failed to filter out the ROWS I expected it to filter,

select="ROW[not(CREDIT_CARDS/CREDIT_CARD/ISSUER= ('ABC','MNO','RST'))]"

Namely, ROW elements which had ISSUER descendants whose text value was one of the three listed strings.

What am I missing here? Am I misusing the not() operator?

Thanks.
-- 
Charles Knell
cknell@xxxxxxxxxx - email

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.