我在Azure搜索上有另一个问题,我有一个名为“branchorders-index”的索引(附加架构)。我有自定义分析器名为“lowerCustomerPONbr”的字符串字段如下:
"analyzers": [
{
"@odata.type": "#Microsoft.Azure.Search.CustomAnalyzer",
"name": "SWMLuceneAlongWithCustomHyphenAnalyser",
"tokenizer": "keyword_v2",
"tokenFilters": [
"lowercase"
],
"charFilters": []
}
]
问题:搜索文本“engg - test - umesh”的正确查询是什么?我想要一个关于执行查询的文档。这是我正在尝试的查询:
$count=true&$select=lowerCustomerPONbr&search=lowerCustomerPONbr:/.*engg\ \-\ test\ \-\ umesh.*/
{
"@odata.context": "https://abcd/indexes('branchorders-index')/$metadata#docs(lowerCustomerPONbr)",
"@odata.count": 8,
"value": [
{
"@search.score": 0.22780417,
"lowerCustomerPONbr": "engg - test - umesh"
},
{
"@search.score": 0.027440047,
"lowerCustomerPONbr": "sam-clc-test-3"
},
{
"@search.score": 0.025132125,
"lowerCustomerPONbr": "sam-clc-test-4"
},
{
"@search.score": 0.019148104,
"lowerCustomerPONbr": "sam-clc-test-1"
},
{
"@search.score": 0.019148104,
"lowerCustomerPONbr": "030 test 17 april"
},
{
"@search.score": 0.018480092,
"lowerCustomerPONbr": "sam-clc-test-2"
},
{
"@search.score": 0.018480092,
"lowerCustomerPONbr": "dilip-qa-test"
},
{
"@search.score": 0.015009361,
"lowerCustomerPONbr": "030 eng-test"
}
]
}