Open gar1t opened 2 months ago
Thank you for your thorough review; the issue does indeed exist.
The specific reason is that the calculation for matches
is separate between frontend and datanode. Datanode does respect the case-sensitive configuration, but this part has not yet been completed in frontend (see TODO): https://github.com/GreptimeTeam/greptimedb/blob/9c1704d4cbbfab8af07a77da598a1cfe2a5e7b22/src/common/function/src/scalars/matches.rs#L75-L95. As it stands, the implementation is currently case-sensitive.
Therefore, until this part of the work is completed, to maintain consistency, I think we can either hardcode this configuration to true
and make it unchangeable, or hardcode it to false
, but then change https://github.com/GreptimeTeam/greptimedb/blob/9c1704d4cbbfab8af07a77da598a1cfe2a5e7b22/src/common/function/src/scalars/matches.rs#L205 to use ilike
, which would be more practical.
In any case, it was indeed an oversight, and I will arrange for a prompt fix.
cc @waynexia
In Quick Start, the query:
shows results that are case-sensitive:
However, the table def is this:
The docs for CREATE indicate that
case_sensitive
forFULLTEXT
istrue
. Based on what I'm seeing, following Quick Start, the default isfalse
.In any event, the query behavior is case sensitive.
Issues as I see them:
case_sensitive
for fulltext indexcase_sensitive
to befalse