我将定义以下变量:
现在我需要做一个条件语句:如果变量pica036E不为空,且pica036F为空,则显示以下信息;否则,显示另一条信息。以下是我的代码,但我没有得到任何输出。 "null or empty" 是否正确定义?
<xsl:variable name="pica036E"
select="recordData/record/datafield[@tag='036E']" />
<xsl:variable name="pica036F"
select="recordData/record/datafield[@tag='036F']" />
现在我需要做一个条件语句:如果变量pica036E不为空,且pica036F为空,则显示以下信息;否则,显示另一条信息。以下是我的代码,但我没有得到任何输出。 "null or empty" 是否正确定义?
<xsl:choose>
<xsl:when test="$pica036E != '' and $pica036F = ''">
<xsl:message>
036F no 036E yes
</xsl:message>
</xsl:when>
<xsl:otherwise>
<xsl:message>
036E no 036F yes
</xsl:message>
</xsl:otherwise>
</xsl:choose>