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

RE: Testing for a pattern

Subject: RE: Testing for a pattern
From: "Michael Kay" <mhk@xxxxxxxxx>
Date: Wed, 24 Sep 2003 17:31:59 +0100
weekno
> 
> I am trying to put together a test that finds the following 
> <col> sequence 'red' 'green' 'yellow' from the following 
> data. I am guessing that the preceding sibling axis is the way?

Try day[col="red" and following-sibling::day[1]/col="green"
and following-sibling::day[2]/col="yellow"]

Michael Kay

> 
> Salud
> 
> John
> 
> 	<asx id="AAC">
> 		<day id="20030825" weekno="5">
> 			<op>127</op>
> 			<hi>132</hi>
> 			<lo>127</lo>
> 			<cl>130</cl>
> 			<vol>1260476</vol>
> 		</day>
> 		<day id="20030826" weekno="5">
> 			<op>131</op>
> 			<hi>133</hi>
> 			<lo>129</lo>
> 			<cl>131</cl>
> 			<vol>1339486</vol>
> 		</day>
> 		<day id="20030827" weekno="5">
> 			<op>131</op>
> 			<hi>131</hi>
> 			<lo>122</lo>
> 			<cl>124</cl>
> 			<vol>683080</vol>
> 			<col>black</col>
> 		</day>
> 		<day id="20030828" weekno="5">
> 			<op>125</op>
> 			<hi>126</hi>
> 			<lo>125</lo>
> 			<cl>125</cl>
> 			<vol>249813</vol>
> 		</day>
> 		<day id="20030829" weekno="5">
> 			<op>126</op>
> 			<hi>127</hi>
> 			<lo>125</lo>
> 			<cl>127</cl>
> 			<vol>167443</vol>
> 		</day>
> 		<day id="20030901" weekno="6">
> 			<op>127</op>
> 			<hi>128</hi>
> 			<lo>125</lo>
> 			<cl>125</cl>
> 			<vol>219555</vol>
> 		</day>
> 		<day id="20030902" weekno="6">
> 			<op>127</op>
> 			<hi>128</hi>
> 			<lo>126</lo>
> 			<cl>127</cl>
> 			<vol>102461</vol>
> 		</day>
> 		<day id="20030903" weekno="6">
> 			<op>128</op>
> 			<hi>128</hi>
> 			<lo>126</lo>
> 			<cl>128</cl>
> 			<vol>96453</vol>
> 		</day>
> 		<day id="20030904" weekno="6">
> 			<op>126</op>
> 			<hi>129</hi>
> 			<lo>126</lo>
> 			<cl>127</cl>
> 			<vol>119890</vol>
> 		</day>
> 		<day id="20030905" weekno="6">
> 			<op>129</op>
> 			<hi>129</hi>
> 			<lo>127</lo>
> 			<cl>128</cl>
> 			<vol>99757</vol>
> 		</day>
> 		<day id="20030908" weekno="7">
> 			<op>129</op>
> 			<hi>130</hi>
> 			<lo>125</lo>
> 			<cl>125</cl>
> 			<vol>359112</vol>
> 		</day>
> 		<day id="20030909" weekno="7">
> 			<op>123</op>
> 			<hi>125</hi>
> 			<lo>119</lo>
> 			<cl>121</cl>
> 			<vol>695000</vol>
> 		</day>
> 		<day id="20030910" weekno="7">
> 			<op>121</op>
> 			<hi>125</hi>
> 			<lo>121</lo>
> 			<cl>125</cl>
> 			<vol>3705877</vol>
> 		</day>
> 		<day id="20030911" weekno="7">
> 			<op>125</op>
> 			<hi>127</hi>
> 			<lo>124</lo>
> 			<cl>127</cl>
> 			<vol>2037264</vol>
> 		</day>
> 		<day id="20030912" weekno="7">
> 			<op>129</op>
> 			<hi>129</hi>
> 			<lo>126</lo>
> 			<cl>128</cl>
> 			<vol>329914</vol>
> 		</day>
> 		<day id="20030915" weekno="8">
> 			<op>129</op>
> 			<hi>130</hi>
> 			<lo>129</lo>
> 			<cl>129</cl>
> 			<vol>119750</vol>
> 		</day>
> 		<day id="20030916" weekno="8">
> 			<op>129</op>
> 			<hi>129</hi>
> 			<lo>127</lo>
> 			<cl>128</cl>
> 			<vol>1150373</vol>
> 			<col>red</col>
> 		</day>
> 		<day id="20030917" weekno="8">
> 			<op>128</op>
> 			<hi>129</hi>
> 			<lo>126</lo>
> 			<cl>126</cl>
> 			<vol>102518</vol>
> 			<col>green</col>
> 		</day>
> 		<day id="20030918" weekno="8">
> 			<op>126</op>
> 			<hi>128</hi>
> 			<lo>126</lo>
> 			<cl>128</cl>
> 			<vol>150199</vol>
> 			<col>yellow</col>
> 		</day>
> 		<day id="20030919" weekno="8">
> 			<op>128</op>
> 			<hi>129</hi>
> 			<lo>127</lo>
> 			<cl>129</cl>
> 			<vol>82481</vol>
> 		</day>
> 	</asx>
> 
> 
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
> 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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.