We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f11ca93 commit d2f5902Copy full SHA for d2f5902
1 file changed
opensearch/src/main/java/org/opensearch/sql/opensearch/data/value/OpenSearchExprValueFactory.java
@@ -190,7 +190,12 @@ private ExprValue parse(
190
191
// Field type may be not defined in mapping if users have disabled dynamic mapping.
192
// Then try to parse content directly based on the value itself
193
- if (fieldType.isEmpty()) {
+ // Besides, sub-fields of generated objects are also of type UNDEFINED. We parse the content
194
+ // directly on the value itself for this case as well.
195
+ // TODO: Remove the second condition once https://github.com/opensearch-project/sql/issues/3751
196
+ // is resolved
197
+ if (fieldType.isEmpty()
198
+ || fieldType.get().equals(OpenSearchDataType.of(ExprCoreType.UNDEFINED))) {
199
return parseContent(content);
200
}
201
0 commit comments