donutTest.json (在我的本地系统 /home/dev 中):
{
"id":"0001",
"type":"donut",
"name":"Cake",
"batter":{
"id":"1001",
"type":"Regular"
},
"topping":[
{ "id":"5001", "type":"None"},
{ "id":"5002", "type":"Glazed"}
]
}
此查询工作正常。
select topping[0].id as topping_id, topping[3].type as topping_type from dfs.`/home/dev/donutTest.json`;
但是当我尝试时:
select batter.id as batter_id, batter.type as batter_type from dfs.`/home/dev/donutTest.json`;
它显示错误。
找不到表“击球手”
topping[0]
并且batter
两者都是嵌入式文档仍然错误。