Skip to content

Commit fea27a1

Browse files
committed
update
1 parent 4ffeb1c commit fea27a1

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1050,10 +1050,18 @@ binary types:
10501050
other types:
10511051
- geometry /* non-jdbc type, extension with limited support */
10521052

1053-
## 64 bit integers in JavaScript
1053+
## Data types in JavaScript
1054+
1055+
Javascript and Javascript object notation are not very well suited for reading database records. Decimal, date/time, binary and geometry types are represented as strings in JSON (binary is base64 encoded, geometries are in WKT format). Below are two more serious issues described.
1056+
1057+
### 64 bit integers
10541058

10551059
JavaScript does not support 64 bit integers. All numbers are stored as 64 bit floating point values. The mantissa of a 64 bit floating point number is only 53 bit and that is why all integer numbers bigger than 53 bit may cause problems in JavaScript.
10561060

1061+
### Inf and NaN floats
1062+
1063+
The valid floating point values 'Infinite' (calculated with '1/0') and 'Not a Number' (calculated with '0/0') cannot be expressed in JSON, as they are not supported by the [JSON specification](https://www.json.org). When these values are stored in a database then you cannot read them as it outputs records as JSON.
1064+
10571065
## Errors
10581066

10591067
The following errors may be reported:

0 commit comments

Comments
 (0)