[saxon] Saxon 6.5.3 boolean function From: - 2005-09-07 23:37:39 Attachments: Message as HTML ```Hi =20 I'm using the boolean function in Saxon 6.5.3. If I pass 'false' I get = true as the result. For example: =20 =20 The result is true. =20 Is there something wrong with the function? =20 Regards, =20 N=E9stor Bosc=E1n ```
 Re: [saxon] Saxon 6.5.3 boolean function From: andrew welch - 2005-09-08 08:31:51 ```> I'm using the boolean function in Saxon 6.5.3. If I pass 'false' I get tr= ue > as the result. For example:=20 > =20 > =20 > =20 > The result is true.=20 > =20 > Is there something wrong with the function?=20 This a faq: http://www.dpawson.co.uk/xsl/sect2/bool.html#d2657e54 However that's quite a long winded answer... basically the boolean value of a string is true if it non-empty and false if it is empty.=20 The string 'false' is non-empty and therefore returns true. You would want to use the functions true() and false() eg select=3D"boolean(true())" or simply select=3D"true()". cheers andrew ```
 RE: [saxon] Saxon 6.5.3 boolean function From: Michael Kay - 2005-09-08 08:36:24 Attachments: Message as HTML ```No, the spec says that when converting from a string to a boolean, the zero-length string is treated as "false" and everything else is treated = as "true". =20 Michael Kay http://www.saxonica.com/ _____ =20 From: saxon-help-admin@... [mailto:saxon-help-admin@...] On Behalf Of N=E9stor = Bosc=E1n Sent: 08 September 2005 00:37 To: saxon-help@... Subject: [saxon] Saxon 6.5.3 boolean function Hi =20 I'm using the boolean function in Saxon 6.5.3. If I pass 'false' I get = true as the result. For example: =20 =20 The result is true. =20 Is there something wrong with the function? =20 Regards, =20 N=E9stor Bosc=E1n ```