xml-xindice-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shilpa R. Kelkar" <skel...@trstone.com>
Subject TO retreive the tree structure
Date Mon, 29 Sep 2003 13:49:16 GMT
I have following xml doc added to the collection products


<?xml version="1.0"?>
<product>
   <id>level1</id>
   <unit>
    <id>first</id>
	<lesson>
	<type>121</type>
	   <frame>
	   <type>1</type>
		<Picture>
		 <type>pct0101</type>
		</Picture>
		<sound>
		<type>snd0101</type>
		</sound>
		<text>
		<id>txt0101</id>
		</text>
	   </frame>
	  </lesson>

	<lesson>
	<type>141</type>
	   <frame>
	   <type>1</type>
		<Picture>
		 <type>pct0201</type>
		</Picture>
		<sound>
		<type>snd0201</type>
		</sound>
		<text>
		<id>txt0201</id>
		</text>
	   </frame>
	  </lesson>
      </unit>
   <unit>
    <id>second</id>
	<lesson>
	<type>221</type>
	   <frame>
	   <type>1</type>
		<Picture>
		 <type>pct0101</type>
		</Picture>
		<sound>
		<type>snd0101</type>
		</sound>
		<text>
		<id>txt0101</id>
		</text>
	   </frame>
	  </lesson>

	<lesson>
	<type>111</type>
	   <frame>
	   <type>1</type>
		<Picture>
		 <type>pct0201</type>
		</Picture>
		<sound>
		<type>snd0201</type>
		</sound>
		<text>
		<id>txt0201</id>
		</text>
	   </frame>
	  </lesson>
      </unit>
</product>

If I execute a query -q //text[@id='txt0201']  , I will get the result as
<text> <id>txt0201</id></text>

How can I get the corresponding lesson type and unit id ??

Shilpa




Mime
View raw message