Can someone explain to me why this is not allowed and suggest an alternative. I understand that I could use the xpath if. However, I have to stick to XPath 1.0 for this.
<xsl:when test="$found_rows < $limit">
<xsl:variable name="pages" select="1"/>
<xsl:variable name="pages" select="ceiling($found_rows div $limit)"/>