Change json format into csv format