Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Hi, I have many JSONs in a folder an I need to combine and transform with power query.
The issue is that the JSONs have different date ranges, so when I try to Export all the JSONs from a folder, it gives me an error.
This are 2 sample files:
https://www.dropbox.com/s/ubg8xfa6vuqef8d/out_nuevog1.json?dl=0
https://www.dropbox.com/s/voo3mlycf6ui22w/out_nuevog2.json?dl=0
Combining the files is the easy part
let
Source = Folder.Files("C:\Users\xxx\Downloads"),
#"Filtered Rows" = Table.SelectRows(Source, each Text.StartsWith([Name], "out_n")),
#"Removed Other Columns" = Table.SelectColumns(#"Filtered Rows",{"Content", "Name"}),
#"Added Custom" = Table.AddColumn(#"Removed Other Columns", "Custom", each Record.ToTable(Json.Document([Content],1252))),
#"Expanded Custom" = Table.ExpandTableColumn(#"Added Custom", "Custom", {"Name", "Value"}, {"Name.1", "Value"})
in
#"Expanded Custom"
But then you have to decide how to parse the JSON - that is something you need to do before you can continue.
| User | Count |
|---|---|
| 60 | |
| 46 | |
| 32 | |
| 16 | |
| 16 |
| User | Count |
|---|---|
| 82 | |
| 68 | |
| 43 | |
| 26 | |
| 25 |