Numbers in Table and JSON are different

I noticed strange thing in logs: the number-value of marker in table-view differs from the corresponding value of field in JSON. What is this?
image
image

The numbers are too big for the browser to handle them. Javascript uses a double (64 bit floating point) to represent numbers internally. If the actual numbers are too big to be represented accurately, they will loose precision when the JSON from the server is parsed.

In your specific case you should store the ids as strings instead of numbers, then you won't run into these problems. In general you should only store values as numbers if you want to do arithmetic operations which is normally not the case for ids.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.