pingcap / pingcap/tidb

planner: FTS query enhancements

Open
#68,714 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

report/customer sig/planner type/enhancement
Dominant language
Go
Stars
40.6k
Forks
6.2k
PR merge metrics
PR metrics pending

Description

Enhancement

We identified several potential enhancements for FTS queries on the optimizer:

  1. The LIKE fallback can't support quoted words, for example, match(col) against('"word"') is not support, but actually it has the same semantic with match(col) against('word'), we should support it.
  2. The default estimation of match against is min(rows/10, 1000), which is not good for large tables with low NDV; A better formula could be rows/NDV.
  3. Sometimes the optimizer could return this error No access path for table 't' is found with 'tidb_isolation_read_engines' = 'tikv,tiflash,tidb', valid values can be 'tici'. Please check tiflash replica., we should fix it.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no files or tests. Start by locating the optimizer's FTS query handling and reproduce the quoted-word LIKE fallback, match-against estimation, and tidb_isolation_read_engines error. Done should cover the three proposed behaviors with regression tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, sql
Domain
databases
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.