Automatic parsing of complex schema
Suppose we are to parse the following JSON string into the complex output schema shown below.
[
{
"FirstName":"Alice",
"LastName":"Smith",
"Phones": [
{
"Type": "Mobile",
"Number": "+420721234567"
},
{
"Type": "Home",
"Number": "+420722345678"
}
]
},
{
"FirstName":"Bob",
"LastName":"Johnson",
"Phones": [
{
"Type": "Mobile",
"Number": "+420723456789"
}
]
}
]
Output schema
Column |
Data type |
FirstName |
string |
LastName |
string |
Phones |
Complex/PhoneNumber |
PhoneNumber schema
Column |
Data type |
Type |
string |
Number |
string |
The connector automatically parses JSON by binding JSON properties to the corresponding columns of the output schema, including nested one.
Result
FirstName: string |
LastName: string |
Phones: Complex/PhoneNumber |
Alice |
Smith |
* Nested table 1 |
Bob |
Johnson |
* Nested table 2 |
Nested table 1
Type: string |
Number: string |
Mobile |
+420721234567 |
Home |
+420722345678 |
Nested table 2
Type: string |
Number: string |
Mobile |
+420723456789 |