I am looking a code snippet to find the best practice to read multiple nested JSON files under sub directories in hadoop using scala .
If we can write into one single file in some other directory in hadoop the above JSON files , that would be even better .
Any help is appreciated.
Thanks PG
sqlContext.read.json("json file path")to read json file, it returns anDataFrame. But you said nested directories, is the json files are having different schemas?