XPath question
"Denny, Allison (LNG-BET)" <[email protected]> Fri, 16 Jan 2004 18:32:17 -0500
| Newsgroups | gmane.text.xml.schematron |
|---|---|
| Message-ID | <38A60BEBEF60234CB599A1FD4BE466E501185FC0@lnxbetexch00.lexis-nexis.com> |
Hello, I'd like to create one schematron template that treats the same element differently based on the presence of a child. If the element has a certain daughter, there are two validations. If not, the same element has more validations. But I don't seem to be able to create a <rule> element containing a 'not', and I can't think how else to do this. Can anyone help? <rule context="PUB-ENTRY/BIB/NOTICE[@WITH-DOCUMENT='NO']"> is fine <rule context="PUB-ENTRY and not(BIB/NOTICE[@WITH-DOCUMENT='NO'])> throws an error <rule context="PUB-ENTRY"> + <rule context="PUB-ENTRY/BIB/NOTICE[@WITH-DOCUMENT='NO']"> incorrectly runs all validations Thanks in advance! Allison Denny XML data analyst LexisNexis ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn