Details
-
Task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
None
Description
The enumeration Item::Type has data-type specific constants for literals:
- STRING_ITEM
- INT_ITEM
- REAL_ITEM
- DECIMAL_ITEM
- DATE_ITEM
This is not friendly to upcoming data type plugins, as they'll need to create their own literals.
We'll do the following:
- Remove the data type specific enumeration values from Item::Type
- Add a new value CONST_ITEM
- Fix the calling code to test for CONST_ITEM, and when it is necessary, detect the data type using other means, such as type_handler(), or by adding new virtual methods into Item or its descendants.
Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() (when assigned to an integer value), reports itself as INT_ITEM. This makes parameter work as a position rather than an expression when used in ORDER BY:
if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && |
!from_window_spec)
|
This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this.
Attachments
Issue Links
- blocks
-
MDEV-4912 Data type plugin API version 1
-
- Closed
-
-
MDEV-15654 ADDTIME creates invalid timestamp value near DST changes
-
- Closed
-
- is blocked by
-
MDEV-15597 Add class Load_data_outvar and avoid using Item::STRING_ITEM for Item_user_var_as_out_param detection
-
- Closed
-
-
MDEV-15689 Fix Item_func_set_collation to pass the collation using CHARSET_INFO instead of Item
-
- Closed
-
-
MDEV-15702 Remove the use of STRING_ITEM from Item_func_date_format::fix_length_and_dec()
-
- Closed
-
-
MDEV-15714 Remove the use of STRING_ITEM from the parser
-
- Closed
-
-
MDEV-16309 Split ::create_tmp_field() into virtual methods in Item
-
- Closed
-
-
MDEV-16316 Replace INT_ITEM references in the code behind ORDER, LIMIT, PROCEDURE clause
-
- Closed
-
-
MDEV-16320 Replace INT_ITEM references in sql_select.cc
-
- Closed
-
-
MDEV-16379 Move Item_basic_const::used_table_map to Item_cache
-
- Closed
-
-
MDEV-16388 Replace member Item::fixed to virtual method is_fixed()
-
- Closed
-
-
MDEV-16408 Remove tests for Item::type() in Item_basic_value::eq()
-
- Closed
-
Activity
Summary | Replace {STRING|INT|REAL|DECIMAL|DATE_ITEM} to LITERAL_ITEM | Replace {STRING|INT|REAL|DECIMAL|DATE}_ITEM to LITERAL_ITEM |
Description |
The enumeration {{Item::Type}} has data-type specific constants:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins. We'll do the following: - Remove the data type specific enumeration values - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins. We'll do the following: - Remove the data type specific enumeration values - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. |
Description |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins. We'll do the following: - Remove the data type specific enumeration values - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. |
Description |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. |
Link |
This issue is blocked by |
Link |
This issue is blocked by |
Link |
This issue is blocked by |
Link | This issue is blocked by MDEV-15704 [ MDEV-15704 ] |
Link |
This issue is blocked by |
Description |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() assigned to an integer value, reports itself as {{INT_ITEM}}. This makes parameter work as a position rather than an expression when used in {{ORDER BY}}: {code:cpp} if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && !from_window_spec) {code} This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this. |
Description |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}. Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() assigned to an integer value, reports itself as {{INT_ITEM}}. This makes parameter work as a position rather than an expression when used in {{ORDER BY}}: {code:cpp} if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && !from_window_spec) {code} This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this. |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}, or by adding new virtual methods into Item or its descendants. Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() assigned to an integer value, reports itself as {{INT_ITEM}}. This makes parameter work as a position rather than an expression when used in {{ORDER BY}}: {code:cpp} if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && !from_window_spec) {code} This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this. |
Description |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}, or by adding new virtual methods into Item or its descendants. Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() assigned to an integer value, reports itself as {{INT_ITEM}}. This makes parameter work as a position rather than an expression when used in {{ORDER BY}}: {code:cpp} if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && !from_window_spec) {code} This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this. |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}, or by adding new virtual methods into Item or its descendants. Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() (when assigned to an integer value), reports itself as {{INT_ITEM}}. This makes parameter work as a position rather than an expression when used in {{ORDER BY}}: {code:cpp} if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && !from_window_spec) {code} This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this. |
Link |
This issue is blocked by |
Fix Version/s | 10.4 [ 22408 ] | |
Fix Version/s | 10.3 [ 22126 ] |
Link |
This issue is blocked by |
Link |
This issue is blocked by |
Link |
This issue is blocked by |
Link |
This issue is blocked by |
Link |
This issue blocks |
Link |
This issue is blocked by |
Summary | Replace {STRING|INT|REAL|DECIMAL|DATE}_ITEM to LITERAL_ITEM | Replace {STRING|INT|REAL|DECIMAL|DATE}_ITEM to CONST_ITEM |
Description |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{LITERAL_ITEM}} - Fix the calling code to test for {{LITERAL_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}, or by adding new virtual methods into Item or its descendants. Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() (when assigned to an integer value), reports itself as {{INT_ITEM}}. This makes parameter work as a position rather than an expression when used in {{ORDER BY}}: {code:cpp} if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && !from_window_spec) {code} This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this. |
The enumeration {{Item::Type}} has data-type specific constants for literals:
- STRING_ITEM - INT_ITEM - REAL_ITEM - DECIMAL_ITEM - DATE_ITEM This is not friendly to upcoming data type plugins, as they'll need to create their own literals. We'll do the following: - Remove the data type specific enumeration values from {{Item::Type}} - Add a new value {{CONST_ITEM}} - Fix the calling code to test for {{CONST_ITEM}}, and when it is necessary, detect the data type using other means, such as {{type_handler()}}, or by adding new virtual methods into Item or its descendants. Note, under terms of this task, we'll preserve the old behavior. For example, Item_param::type() (when assigned to an integer value), reports itself as {{INT_ITEM}}. This makes parameter work as a position rather than an expression when used in {{ORDER BY}}: {code:cpp} if (order_item->type() == Item::INT_ITEM && order_item->basic_const_item() && !from_window_spec) {code} This behavior was most likely introduced as a side effect. The new implementation will preserve the old behavior, including side effects like this. |
issue.field.resolutiondate | 2018-06-06 10:09:26.0 | 2018-06-06 10:09:26.602 |
Fix Version/s | 10.4.0 [ 23115 ] | |
Fix Version/s | 10.4 [ 22408 ] | |
Resolution | Fixed [ 1 ] | |
Status | Open [ 1 ] | Closed [ 6 ] |
Link | This issue is blocked by MDEV-15704 [ MDEV-15704 ] |
Workflow | MariaDB v3 [ 84390 ] | MariaDB v4 [ 133418 ] |