尝试将日期转换为特定格式但出现错误:
<xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.openapplications.org/oagis/9"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xsl:variable name="origDate" select="row[@num='6']/cell[@num='2']"/>
<PromisedDeliveryDateTime><xsl:value-of select="format-date(xs:date($origDate), '[Y] [M] [D]')" /></PromisedDeliveryDateTime>
但我得到了错误:
未能转换 XQMessage 部分,索引 = 0(无效日期“30.11.2011”
(非数字组件)