amorynan commented on code in PR #41290:
URL: https://github.com/apache/doris/pull/41290#discussion_r1826952018


##########
be/src/vec/exec/format/json/new_json_reader.cpp:
##########
@@ -330,6 +330,10 @@ Status 
NewJsonReader::get_parsed_schema(std::vector<std::string>* col_names,
         objectValue = _json_doc;
     }
 
+    if (!objectValue->IsObject()) {
+        return Status::DataQualityError("JSON data is not an object.");

Review Comment:
   this function just for scanner to read json file when in tvf , other load 
will not call  this function 
   just with VFileScanner::_get_block_wrapped --> NewJsonReader::get_next_block 
--> NewJsonReader::_read_json_column --> NewJsonReader::_vhandle_simple_json 
--> NewJsonReader::_set_column_value



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to