pandas和SQL数据分析实战
https://study.163.com/course/courseMain.htm?courseId=1006383008&share=2&shareId=400000000398149
转载
https://www.cnblogs.com/drjava/p/10486134.html
hive提供了json的解析函数:get_json_object
使用方法
对于jsonArray(json数组),如person表的xjson字段有数据:
[{"name":"王二狗","sex":"男","age":"25"},{"name":"李狗嗨","sex":"男","age":"47"}]
取出第一个json对象,那么hive sql为:
SELECT get_json_object(xjson,"$.[0]") FROM person;
结果是:
{"name":"王二狗","sex":"男","age":"25"}
取出第一个json的age字段的值:
SELECT get_json_object(xjson,"$.[0].age") FROM person;
结果
25
总结
get_json_object(param1,"$.param2")
python机器学习-sklearn挖掘乳腺癌细胞( 博主亲自录制)
网易云观看地址
扫二维码,关注博主主页,学习更多Python知识