http://www.zorba-xquery.com/modules/excel/information
Description
Before using any of the functions below please remember to import the module namespace:
import module namespace excel-information = "http://www.zorba-xquery.com/modules/excel/information";
This is a library module offering the same set of functions defined by Microsoft Excel, under Information Functions.
See also
Author
Sorin Nasoi
XQuery version and encoding
xquery version "3.0" encoding "utf-8";
Namespaces
| excel-err | http://www.zorba-xquery.com/modules/excel/errors |
| excel-information | http://www.zorba-xquery.com/modules/excel/information |
| excel-math | http://www.zorba-xquery.com/modules/excel/math |
| ver | http://www.zorba-xquery.com/options/versioning |
Function Summary
is-blank($value as xs:anyAtomicType?) as xs:booleanTest if the passed argument is empty of not. | |
is-even($value as xs:anyAtomicType?) as xs:booleanTest is a number is even. | |
is-odd($value as xs:anyAtomicType?) as xs:booleanTest is a number is odd. | |
islogical($value as xs:anyAtomicType?) as xs:booleanTests if the passed $value is a logical value. | |
isnumber($value as xs:anyAtomicType?) as xs:booleanTests if the passed $value is a number. | |
istext($value as xs:anyAtomicType?) as xs:booleanTests if the passed $value is a string. | |
n($value as xs:anyAtomicType?) as xs:anyAtomicTypeConverts a $value to a number. | |
na() as xs:anyAtomicTypeRaises the error value #N/A. |
Functions
is-blank#1
declare function excel-information:is-blank(
$value as xs:anyAtomicType?
) as xs:booleanTest if the passed argument is empty of not.
Parameters
$value as xs:anyAtomicTypethe value.
Returns
xs:booleanIf the value of $arg is the empty sequence, the function returns true, otherwise the function returns false.
See also
is-even#1
declare function excel-information:is-even(
$value as xs:anyAtomicType?
) as xs:booleanTest is a number is even.
Parameters
$value as xs:anyAtomicTypethe value.
Returns
xs:booleanTRUE if number is even, FALSE if number is odd.
Errors
- excel-err:Value if provided value is not a number.
See also
is-odd#1
declare function excel-information:is-odd(
$value as xs:anyAtomicType?
) as xs:booleanTest is a number is odd.
Parameters
$value as xs:anyAtomicTypethe value.
Returns
xs:booleanTRUE if number is odd, FALSE if number is even.
Errors
- excel-err:Value if provided value is not a number.
See also
islogical#1
declare function excel-information:islogical(
$value as xs:anyAtomicType?
) as xs:booleanTests if the passed $value is a logical value.
Parameters
$value as xs:anyAtomicTypethe value.
Returns
xs:booleanTRUE if $value refers to a logical value.
See also
isnumber#1
declare function excel-information:isnumber(
$value as xs:anyAtomicType?
) as xs:booleanTests if the passed $value is a number.
Parameters
$value as xs:anyAtomicTypethe value.
Returns
xs:booleanTRUE if $value refers to a number.
See also
istext#1
declare function excel-information:istext(
$value as xs:anyAtomicType?
) as xs:booleanTests if the passed $value is a string.
Parameters
$value as xs:anyAtomicTypethe value.
Returns
xs:booleanTRUE if $value refers to text.
See also
n#1
declare function excel-information:n(
$value as xs:anyAtomicType?
) as xs:anyAtomicTypeConverts a $value to a number.
Parameters
$value as xs:anyAtomicTypethe value.
Returns
xs:anyAtomicTypeA $value converted to a number.
See also
na#0
declare function excel-information:na() as xs:anyAtomicType
Raises the error value #N/A.
Returns
xs:anyAtomicTypeThe error value #N/A. #N/A is the error value that means "no value is available."
Errors
- excel-err:NA the purpose of this function is to raise this error