Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
So I need help trying to parse my json file from an API… I haven't been able to succesfully parse this into a table. I am receiving the following error:
"Expression.Error: We cannot convert a value of type Record to type Text.
Details:
Value=
379662=379662
396454=396454
396455=396455" ... etc etc
The function I am using looks like:
And the table:
In the image above you can also see my table failing. I'm trying to get this information listed in a single table with each row being a seperate purchase ID.
Any help would be greatly appreciated!
Solved! Go to Solution.
Hello @jcawley
check out this solution. It converts the json to a table with two column, using the field "purchase_ids" from your api output
let
YourJson = "{""total_found"":3, ""purchase_ids"":{""444636"":""444636"", ""444637"":""444637"", ""444638"": ""444638""}}",
ReadJson = Json.Document(YourJson),
CreateTable = Record.ToTable(ReadJson[#"purchase_ids"])
in
CreateTable
Copy paste this code to the advanced editor in a new blank query to see how the solution works.
If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too
Have fun
Jimmy
Also, here is an image from the webpage we are trying to parse the data from:
Hello @jcawley
check out this solution. It converts the json to a table with two column, using the field "purchase_ids" from your api output
let
YourJson = "{""total_found"":3, ""purchase_ids"":{""444636"":""444636"", ""444637"":""444637"", ""444638"": ""444638""}}",
ReadJson = Json.Document(YourJson),
CreateTable = Record.ToTable(ReadJson[#"purchase_ids"])
in
CreateTable
Copy paste this code to the advanced editor in a new blank query to see how the solution works.
If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too
Have fun
Jimmy
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 5 | |
| 4 | |
| 3 | |
| 3 | |
| 2 |
| User | Count |
|---|---|
| 8 | |
| 8 | |
| 6 | |
| 6 | |
| 5 |