Complex dataType in Hive

50 Views Asked by At

Hi Is there any option to create hive table on below hdfs file.So lets say if I query with on customer then it should return all the columns for customer in a single row in json format.

Hdfs File Content:

{
"customer": {
    "legalBusinessName": "testing",
    "organisationIdentifications": [{
        "type": "test",
        "identification": "test102.abc@xyz"
    }, {
        "type": "test",
        "identification": "12345678"
    }]
},
"seller": {
    "legalBusinessName": "testing",
    "organisationIdentifications": [{
        "type": "test",
        "identification": "test"
    }]
},

"RecommendationId": "testid",
"excludedRemittanceInformation": [],
"recommendedPaymentInstructions": [{
    "executionDate": "2022-06-12",
    "remittanceInformation": {
        "structured": [{
            "referredDocumentInformation": [{
                "paymentDueDate": "2022-06-12",

                "referredDocumentAmount": {
                    "duePayableAmount": 3000
                }
            }]
        }]
    }
}]

}

File Structure :

enter image description here

0

There are 0 best solutions below