-
Notifications
You must be signed in to change notification settings - Fork 5.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
read_from_storage
hint doesn't effect while plan choose the index merge plan
#56217
Comments
WorkaroundI try to disable the index merge path by hint
|
/*+ read_from_storage(tiflash[a]) */ doesn't isolate the storage as tiflash, tikv is also included when CBO does the math. |
The read_from_storage hint is a prefer hint of storage engine which means if there is a matched path of prefer engine, this path will be chosen. The @@tidb_isolation_read_engines is an enforce session variable which means optimizer only can choose the matched engine path. In this case, the correct behavior is that optimizer choose the tiflash path when there is a hint /*+ read_from_storage(tiflash[a]) */ in the query |
Bug Report
1. Minimal reproduce step (Required)
add tiflash replica
insert some data
query hint with read_from_storage(tiflash[xx])
2. What did you expect to see? (Required)
3. What did you see instead (Required)
The hint doesn't effect. The query plan choose the index merge plan instead of tiflash plan.
4. What is your TiDB version? (Required)
v6.5.7
The text was updated successfully, but these errors were encountered: