Details
-
Bug
-
Resolution: Fixed
-
Major
-
6.0.0, 6.6.0, 6.5.0, Cheshire-Cat
-
Untriaged
-
1
-
Unknown
Description
Build : 7.0.0-1834
On the travel-sample dataset, created an FTS index with default mapping and analyzer=keyword. This index was on 3 fields - city, name and type - all strings with analyzer inherited. The Overall default analyzer for the index is Standard. So expecting the fields would have keyword analyzer as that is the one it would inherit. The index definition is attached.
Now running a query like the below one doesnt return any results even though the above index is used. See the plan as well.
select name from `travel-sample` use index(using fts) where city="San Jose" and name="San Jose Municipal Rose Garden";
|
|
{
|
"#operator": "Authorize",
|
"#stats": {
|
"#phaseSwitches": 4,
|
"execTime": "8.377µs",
|
"servTime": "4.914979ms"
|
},
|
"privileges": {
|
"List": [
|
{
|
"Target": "default:travel-sample",
|
"Priv": 7
|
}
|
]
|
},
|
"~child": {
|
"#operator": "Sequence",
|
"#stats": {
|
"#phaseSwitches": 1,
|
"execTime": "8.293µs"
|
},
|
"~children": [
|
{
|
"#operator": "IndexFtsSearch",
|
"#stats": {
|
"#phaseSwitches": 3,
|
"execTime": "26.715µs",
|
"servTime": "3.13043ms"
|
},
|
"index": "def_city_name_type",
|
"index_id": "1b27030adce0e0b3",
|
"keyspace": "travel-sample",
|
"namespace": "default",
|
"search_info": {
|
"field": "\"\"",
|
"options": "{\"index\": \"def_city_name_type\"}",
|
"outname": "out",
|
"query": "{\"query\": {\"conjuncts\": [{\"field\": \"city\", \"term\": \"San Jose\"}, {\"field\": \"name\", \"term\": \"San Jose Municipal Rose Garden\"}]}, \"score\": \"none\"}"
|
},
|
"using": "fts",
|
"#time_normal": "00:00.003",
|
"#time_absolute": 0.003157145
|
},
|
{
|
"#operator": "Fetch",
|
"#stats": {
|
"#phaseSwitches": 4,
|
"execTime": "20.125µs",
|
"kernTime": "3.16398ms"
|
},
|
"keyspace": "travel-sample",
|
"namespace": "default",
|
"#time_normal": "00:00.000",
|
"#time_absolute": 0.000020125
|
},
|
{
|
"#operator": "Sequence",
|
"#stats": {
|
"#phaseSwitches": 1,
|
"execTime": "4.759µs"
|
},
|
"~children": [
|
{
|
"#operator": "Filter",
|
"#stats": {
|
"#phaseSwitches": 4,
|
"execTime": "26.132µs",
|
"kernTime": "3.192025ms"
|
},
|
"condition": "(((`travel-sample`.`city`) = \"San Jose\") and ((`travel-sample`.`name`) = \"San Jose Municipal Rose Garden\"))",
|
"#time_normal": "00:00.000",
|
"#time_absolute": 0.000026132
|
},
|
{
|
"#operator": "InitialProject",
|
"#stats": {
|
"#phaseSwitches": 4,
|
"execTime": "5.497µs",
|
"kernTime": "3.226259ms"
|
},
|
"result_terms": [
|
{
|
"expr": "(`travel-sample`.`name`)"
|
}
|
],
|
"#time_normal": "00:00.000",
|
"#time_absolute": 0.000005497
|
}
|
],
|
"#time_normal": "00:00.000",
|
"#time_absolute": 0.0000047590000000000005
|
},
|
{
|
"#operator": "Stream",
|
"#stats": {
|
"#phaseSwitches": 4,
|
"execTime": "6.202µs",
|
"kernTime": "3.241149ms"
|
},
|
"#time_normal": "00:00.000",
|
"#time_absolute": 0.000006202
|
}
|
],
|
"#time_normal": "00:00.000",
|
"#time_absolute": 0.000008293
|
},
|
"~versions": [
|
"7.0.0-N1QL",
|
"7.0.0-1834-enterprise"
|
],
|
"#time_normal": "00:00.004",
|
"#time_absolute": 0.004923356
|
}
|
The same query with GSI primary index returns one result -
select name from `travel-sample` where city="San Jose" and name="San Jose Municipal Rose Garden";
|
|
[
|
{
|
"name": "San Jose Municipal Rose Garden"
|
}
|
]
|
Attachments
Issue Links
- is duplicated by
-
MB-39094 Flex Index: Default Index: queries returns 0 results for text comparison in predicate
- Closed
-
MB-39095 Flex Index: Default Index: queries returns different results than GSI for between operator
- Closed
-
MB-39258 Flex Index: Default Index: queries with arrays returns 0 results from FTS index
- Closed
-
MB-39266 FlexIndex:Default Index: FTS index not sargable for FlexQuery with like operator with value "Pluto (Disn%"
- Closed
-
MB-39838 FlexIndex:Flex Query returns 0 results after upgrade
- Closed
-
MB-40112 [N1QL][RQG][Flex] flex index with USING FTS,USING GSI hint returns null
- Closed
- relates to
-
MB-36534 Support FTS FLEX index
- Closed
-
MB-39262 FlexIndex:Default Index: FlexQuery gives different results than GSi for range query with email field
- Closed
-
MB-39635 FTS:match query not returning the results
- Closed
-
MB-41536 [N1QL+FTS] During verification set DefaultAnalyzer correctly in case "field" is not specified in FTS query
- Closed