July 2002
Intermediate to advanced
864 pages
22h 32m
English
There are not many data-centric XML documents in which numbers won't play some role in the data, and that is where the decimal type comes in. The decimal type is used to represent decimal numbers with arbitrary precision.
The decimal type allows for a leading sign of “+” or “-” to specify a positive or negative number, although the “+” is the default, so it is not necessary to use it. The type supports any theoretical amount of digits to the right or left of the decimal point, although XML processors are required to support only at least 18 total digits.
Some valid values for decimals include 4, 5.2, -6.3, or 3.14159.
There are a number of constraining attributes that can be used with the decimal type:
totalDigits
fractionDigits
minInclusive ...