We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
由于fed生成schema和写入doc时,将数据结构打平时会用下划线' _ '代替es的句号' . ', 所以对于嵌套的Object对象,fed内部实际上是使用下划线' _ '而不是es所使用的句号' . '来划分层次的, 导致使用查询语句时,需要用' _ '来查询子字段,而不是es的' . ', 例子如下:
#创建索引 PUT test_index3 { "settings": { "index.engine": "havenask", "number_of_shards": 1, "number_of_replicas": 0 }, "mappings": { "properties": { "foo":{ "type":"keyword" }, "user": { "properties": { "name": { "type": "keyword" }, "age": { "type": "integer" }, "image":{ "type":"vector", "dims":"2", "similarity":"l2_norm" } } } } } } #写入数据 PUT /test_index3/_doc/1 { "foo":"test1", "user": { "name": "Alice", "age": "30", "image": [0.5, 0.6] } } PUT /test_index3/_doc/2 { "foo":"test2", "user": { "name": "Bob", "age": "25", "image": [0.4, 0.7] } } PUT /test_index3/_doc/3 { "foo":"test3", "user": { "name": "Charlie", "age": 35, "image": [0.3, 0.8] } } #使用这个查询可以查询到对于的数据 GET /test_index3/_search { "query": { "match": { "user_age": 35 } } } #使用这个查询无法查到数据 GET /test_index3/_search { "query": { "match": { "user.age": 35 } } }
The text was updated successfully, but these errors were encountered:
fixed by:#411
Sorry, something went wrong.
No branches or pull requests
由于fed生成schema和写入doc时,将数据结构打平时会用下划线' _ '代替es的句号' . ',
所以对于嵌套的Object对象,fed内部实际上是使用下划线' _ '而不是es所使用的句号' . '来划分层次的,
导致使用查询语句时,需要用' _ '来查询子字段,而不是es的' . ',
例子如下:
The text was updated successfully, but these errors were encountered: