TomBarrand
Programmer
Hi,
I have an XML document similar to the structure below. I need to know how many <FORECASTDETAIL> elements there are in the document. I used COUNT(/FORECAST/ITEM/MONTH/FORECASTDETAIL), but this only returns the number of <FORECASTDETAIL> elements within one <MONTH> element and not the total number of <FORECASTDETAIL> elements in the document.
Any ideas?
Thanks
<FORECAST>
<ITEM>
<MONTH>
<FORECASTDETAIL></FORECASTDETAIL>
</MONTH>
<MONTH>
<FORECASTDETAIL></FORECASTDETAIL>
</MONTH>
<MONTH>
<FORECASTDETAIL></FORECASTDETAIL>
</MONTH>
</ITEM>
</FORECAST>
I have an XML document similar to the structure below. I need to know how many <FORECASTDETAIL> elements there are in the document. I used COUNT(/FORECAST/ITEM/MONTH/FORECASTDETAIL), but this only returns the number of <FORECASTDETAIL> elements within one <MONTH> element and not the total number of <FORECASTDETAIL> elements in the document.
Any ideas?
Thanks
<FORECAST>
<ITEM>
<MONTH>
<FORECASTDETAIL></FORECASTDETAIL>
</MONTH>
<MONTH>
<FORECASTDETAIL></FORECASTDETAIL>
</MONTH>
<MONTH>
<FORECASTDETAIL></FORECASTDETAIL>
</MONTH>
</ITEM>
</FORECAST>