Date Type checking
Hallo all (or just Hallo Michael :D)
I have an XML data which has a DTD instead of Schema. I need to compare an element value if it is a date type formatted or not. Normally I could write some sort of code like
<xsl:template match="shipDate">
<xsl:if test="not(string(.) castable as xs:date)">
<xsl:text>
Following shipDate value not a date: </xsl:text>
<xsl:value-of select="."/>
</xsl:if>
</xsl:template>
but I am not sure if I can check my element value like that. It would be fine if someone can help me to solve this problem.
Your attitude determines your altitude
__________________
Your attitude determines your altitude
|