ORA-FO-CAST-BOOLEAN 15.1.4 fn:boolean

*Functions and Operators, Section 15.1.4 fn:boolean* says /"If $srcval 
is an atomic value, then the function returns the same value as returned 
by the expression cast as xs:boolean ($srcval) with the one exception 
described below. This exception is for compatibility with [XPath 1.0]. 
Specifically, it returns false if $srcval is: .... "/
It then lists 4 possibilities. What is the "one exception" ?

Possibly the exception is the second bullet - /"The singleton xs:string 
value "". (the zero-length string). The expression cast as xs:boolean 
($srcval) returns false if $srcval is "0" and true if $srcval is "1"."/.
Why are we comparing what fn:boolean does with the zero-length string as 
input vs what cast as xs:boolean does with "0" or "1" as input ?

Suggest: if there is only one difference between fn:boolean and cast as 
xs:boolean, then either describe the behaviour fully in one section and 
just mention the exception in the other, or describe the behaviour 
fully, using the same format and notation, in both sections and note the 
exception in both sections.

Received on Monday, 30 June 2003 10:18:23 UTC