`double` field type new behaviour
Nobody has claimed this yet.
- Dominant language
- CSS
- Stars
- 15
- Forks
- 49
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 3
Description
Related dev. issue(s): https://github.com/tarantool/tarantool/issues/9965
Product: Tarantool
Since: 3.4
Root document:
- https://www.tarantool.io/en/doc/latest/reference/reference_sql/sql_user_guide/#sql-data-type-double
- https://www.tarantool.io/en/doc/latest/platform/ddl_dml/value_store/
SME: @ Gerold103
Details
Double field type now is identical to number. I.e. it can
store integers and compares them as integers.
-
Reference -> SQL reference -> SQL user guide:
DOUBLE values are numerics that do contain decimal points (for
example 0.5) or are expressed with exponential notation (for
example 5E-1) -> now DOUBLE can have any numbers, including
integers. It becomes identical to NUMBER. -
Platform -> Defining and manipulating data -> Data storage:
the storage type is MP_DOUBLE and the size of the encoded
value is always 9 bytes. In Lua, fields of the double type
can only contain non-integer numeric values and cdata values
with double floating-point numbers -> not so anymore.
doublefield is now identical tonumber(it can store
integers too, and compares them like integers).
Requested by @ Gerold103 in https://github.com/tarantool/tarantool/commit/60272e8292ad5a893cc14d0318a30f5cfabb6495.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the SQL data type and Data storage root documents linked in the issue. Check each statement about DOUBLE values, storage encoding, and Lua field values against the behavior described here. Done means both pages accurately state that double accepts integers and is identical to number, including integer comparisons.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua
- Domain
- databases, documentation
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100