Many different datatypes are defined in XML Schema. The available datatypes can be divided into four general categories:
String and name types, which include strings and other datatypes derived from strings.
Date and time types, which include date and time values as well as duration.
Numeric types, which include floating point and decimal values as well as values based on these datatypes.
Miscellaneous types, which encompass all other datatypes not discussed elsewhere and include Boolean and binary values.
To control the acceptable values that can be used with datatypes, you use restrictions. You can use restrictions to assign minimum length, maximum length, or a specific length to element ...