[feature][dingo-executor] Support document index scan filter #1333
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
[feature][dingo-executor] Support document index scan filter
mysql> describe select count(DESCRIPTION) from test3 where DESCRIPTION = 'Keyboard' group by(id);
+------------------------+---------+------------+--------------+--------------------------------------------------------------------------------+
| id | estRows | task | accessObject | info |
+------------------------+---------+------------+--------------+--------------------------------------------------------------------------------+
| root-collect | 15.0 | root | | |
| dingoRelOp | 15.0 | root | | PROJECT: [_[1]] |
| dingoReduceAggregate | 15.0 | root | | AGG: [0][COUNT()] |
| streaming | 15.0 | root | | |
| dingoScanRelOp | 15.0 | root | | batchSize:40960 |
| tableFullScan | 100.0 | cop[store] | TEST3 | parallel = true,FILTER: [3] == 'Keyboard', PROJECT: [[0]], AGG: [0][COUNT()] |
+------------------------+---------+------------+--------------+--------------------------------------------------------------------------------+
6 rows in set (0.17 sec)
mysql> set enable_document_scan_filter = 'on';
Query OK, 0 rows affected (0.01 sec)
mysql> describe select count(DESCRIPTION) from test3 where DESCRIPTION = 'Keyboard' group by(id);
+--------------------------+---------+------+--------------+--------------------------------------------------------------------------------------------------+
| id | estRows | task | accessObject | info |
+--------------------------+---------+------+--------------+--------------------------------------------------------------------------------------------------+
| root-collect | 15.0 | root | | |
| dingoRelOp | 15.0 | root | | PROJECT: [[1]] |
| dingoReduceAggregate | 15.0 | root | | AGG: [0][COUNT()] |
| streaming | 15.0 | root | | |
| dingoRelOp | 15.0 | root | | AGG: [0][COUNT()] |
| dingoRelOp | 15.0 | root | | PROJECT: [[0]] |
| documentScanFilter | 15.0 | root | TEXT_INDEX | parallel=true, condition==($3, _UTF-8'Keyboard'), queryStr: DESCRIPTION:"Keyboard", lookup:false |
+--------------------------+---------+------+--------------+--------------------------------------------------------------------------------------------------+