[
https://issues.apache.org/jira/browse/PHOENIX-5652?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Gokcen Iskender updated PHOENIX-5652:
-------------------------------------
Attachment: PHOENIX-5652.master.001.patch
> IndexScrutinyTool perf improvement to query indexes using skipscanfilter
> ------------------------------------------------------------------------
>
> Key: PHOENIX-5652
> URL: https://issues.apache.org/jira/browse/PHOENIX-5652
> Project: Phoenix
> Issue Type: Improvement
> Reporter: Gokcen Iskender
> Assignee: Gokcen Iskender
> Priority: Major
> Attachments: PHOENIX-5652.master.001.patch
>
>
> When the IndexScrutinyTool uses DATA_TABLE as source (source type DATA_TABLE
> or BOTH), it constructs a query that uses a WHERE IN statement to look up the
> data table entries in the index table.
> Consider a table with ID Integer PK, NAME varchar and index with PK NAME
> The current query is constructed like this:
> IndexTable WHERE (:ID, 0:NAME) IN ()
> The WhereOptimizer looks at the column order to decide whether to use
> SkipScanFilter or not. The PK of the index table should come before the PK of
> data table.
> If the query is written like this:
> IndexTable WHERE (0:NAME, :ID) IN () then SkipScanFilter is used and the
> query is much faster.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)