posted 20 years ago
>I need some XPath which can help me identify all the distinct yyyy-mm in this document.
I don't think there would be any straight forward approach for this. You can achieve the same by manipulating each field.
<xsl:for-each select="response/info/records/field">
<xsl:variable name="test" select="."/>
<xsl:variable name="year" select="substring($test,5,1)"/>
<xsl:variable name="month" select="substring($test,8,1)"/>
//check here that value of year and month are "-". If these variables does not contains "-" then it is not is yyyy-mm format.
</xsl:for-each>
hope this would help.
regards,
Ranjan