File: Data.xml
shop 1
product 1
1998
6.99
5.99
71.50
shop 2
product 2
1997
10.99
9.50
114.00
File: Transform.xslt
">
]>
version="1.0">
&space;
&space;
&space;
other Chardonnays:
select="preceding-sibling::wine[@grape = 'Chardonnay'] |
following-sibling::wine[@grape = 'Chardonnay']">
&space;
Output:
shop 1 product 1 1998 Chardonnay
other Chardonnays:
shop 2 product 2
shop 2 product 2 1997 Chardonnay
other Chardonnays:
shop 1 product 1