Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Error when trying to load Nested JSON file using Ambari > Hive View> Upload Table :E090 Row data cannot have an array. [IllegalArgumentException]

avatar

When I try to upload a simple JSON using Upload Table in Ambari>Hive View I am able to do it.

When I try to upload a nested JSON ( containing one or more different arrays ), I get "E090 Row data cannot have an array. [IllegalArgumentException]."

I am beginning to wonder if Upload Table supports loading complex nested JSON.

Attached complex.txt file that I am trying to load. Please rename it to .json if you want to replicate the issue.

Thank you.

1 ACCEPTED SOLUTION

avatar

It is confirmed that nested objects are not supported in JSON via Upload Table function.

Here is an excerpt from official documentation:

The following json format is supported: [ { "col1Name" : "value-1-1", "col2Name" : "value-1-2"}, { "col1Name" : "value-2-1", "col2Name" : "value-2-2"}]

The file should contain a valid json array containing any number of json objects. Each json object should contain column names as property and column values as property values. The names, number and order of columns in the table are decided from the first object of the json file. The names and datatype of column can be edited during the preview step. If some json objects have extra properties then they are ignored. If they do not have some of the properties then null values are assumed. Note that extension of files cannot be “.json”

View solution in original post

2 REPLIES 2

avatar

@Pardeep @vsithannan - Appreciate any inputs from you guys. I have tried to find the answer on multiple forums to no avail and I am finally posting it here.

avatar

It is confirmed that nested objects are not supported in JSON via Upload Table function.

Here is an excerpt from official documentation:

The following json format is supported: [ { "col1Name" : "value-1-1", "col2Name" : "value-1-2"}, { "col1Name" : "value-2-1", "col2Name" : "value-2-2"}]

The file should contain a valid json array containing any number of json objects. Each json object should contain column names as property and column values as property values. The names, number and order of columns in the table are decided from the first object of the json file. The names and datatype of column can be edited during the preview step. If some json objects have extra properties then they are ignored. If they do not have some of the properties then null values are assumed. Note that extension of files cannot be “.json”