Power BI Tutorial | Working with JSON data

Поделиться
HTML-код
  • Опубликовано: 1 дек 2024

Комментарии • 125

  • @GuyInACube
    @GuyInACube  6 лет назад +5

    David Eldersveld commented on Twitter, and Geoff Richardson commented below, regarding ragged JSON, like with AuditData in the example above. I forgot to call this out in the video. If the structure changes, you could end up with bad results. Imke Feldmann pointed out a possible solution:
    You could replace the hardcoded field names by a formula that expands all of them automatically:
    Record.FieldNames(Record.Combine(PreviousStepName[ExpandColumnName]))

    • @joesamraj
      @joesamraj 5 лет назад

      Hi, I'm new to power bi. Where exactly I have to add that formula? Thanks.

  • @EricWahner
    @EricWahner 6 лет назад +35

    I would love to see a video about connecting to a Web Api (web) resource and show how you can convert a huge JSON response to a I am guessing a series of tables.

    • @GuyInACube
      @GuyInACube  6 лет назад +9

      It is on the list :) ty good sir!

    • @snickersTO
      @snickersTO 6 лет назад +3

      Ditto, any movement on this item? (This was a great video BTW, got my like and subscribe)

    • @swethajella
      @swethajella 6 лет назад +3

      Any update on this yet ?

    • @bigsocks2479
      @bigsocks2479 5 лет назад +1

      @@GuyInACube yo, did this ever happen? ;)

    • @fearless.stryder
      @fearless.stryder 5 лет назад +2

      @@GuyInACube This would be very helpful!

  • @hindia.m
    @hindia.m 8 месяцев назад

    I was not logged in when I first desperately landed on your video. I absolutely loved everything about it that I had to login, subscribe and like AND comment. Thank you!!

  • @oliverocket
    @oliverocket 5 лет назад +5

    Thanks man!! I was breaking my head for two days! You are a legend!

  • @GHRichardson
    @GHRichardson 6 лет назад +2

    Great little tip, Adam. The hours I've spent trying to format the contents of a JSON file...!
    The only issue with what you demo'ed is that if the JSON format is not static, you may end up trying to extract out a field value that doesn't always exist in your specific JSON block. I guess that we could use a try-otherwise block around the line, but that's a bit severe if just one of the fields in the JSON isn't present? What do you think?

    • @GuyInACube
      @GuyInACube  6 лет назад +1

      Yup, I forgot to call out that part in the video. Imke had a solution on Twitter and i'm going to make a comment here and Pin it so others are aware of it. Thanks for calling it out.

  • @arg1871
    @arg1871 4 года назад +1

    Great tutorial, helped me a lot ! Only problem I have now is that the REST API that is feeding the JSON only returns 100 rows at a time, you have to use a revised URL to get the next 100 rows (e.g. &next=100) and so on. How can I get PowerBI to keep getting the next 100 rows until none left ?

  • @drspoerl
    @drspoerl 6 лет назад +4

    Great video. My challenge is that my JSON files have list within unique records. Any help?

  • @TTTTT5050
    @TTTTT5050 2 года назад +1

    can you do a video how to resolve JSON Error "
    We found extra characters at the end of JSON input"

  • @BroadtreeSolutions
    @BroadtreeSolutions 6 лет назад +1

    Came across a json data source from a customer and was able to use this so thank you! it's sweet.

    • @GuyInACube
      @GuyInACube  6 лет назад

      Woot! very awesome! Glad it helped! 👊

  • @benmann4060
    @benmann4060 6 лет назад +4

    Transform>JSON is definitely one of the best kept secrets-- it has definitely saved my life in parsing JSON in PBI. One of the most powerful aspects of the JSON structure is the neigh-unlimited power of nested arrays...but this is also a royal pain to manually expand. E.g. I transform a JSON column into records and expand all columns. Some of these columns contain their own nested arrays of variables and show up as "Records" in the newly expanded column values. Another round of expand columns/expand to rows is needed to unlock the second teir of arrays....and so on and so forth for however many nested variables you have. Is there a way to quickly (and use less lines of code in the query editor, for performance power) expand all columns and nested arrays from a JSON document in Power Query?

    • @GuyInACube
      @GuyInACube  6 лет назад

      That's good feedback Ben! I'm not aware of an easier way to do that today. I can pass on the feedback though.

    • @thebiccountant
      @thebiccountant 6 лет назад +2

      Hi Ben, I've published a function to automatically expand all fields from a JSON here: www.thebiccountant.com/2018/06/17/automatically-expand-all-fields-from-a-json-document-in-power-bi-and-power-query/ It will return a large table with one row per value.
      In an upcoming post I will show a method how to group them together again in a format more suitable for the data model.
      /Imke

    • @joesamraj
      @joesamraj 5 лет назад

      @@thebiccountant Could you please give me the url where you have explained about how to group them together again in a format more suitable for the data model.

  • @DRockDaddio34
    @DRockDaddio34 5 лет назад +1

    Thank you for this. This was very helpful.
    I now seem to be going down a rabbit hole with my Sharepoint data - Seems there are lists within the JSON data and records within these lists and the list data needs to be pivoted. I'm lost!
    I've been told to turn the lists into tables, but how do I tie those tables back to the rest of the data in the record and, most importantly, how do I make this repeatable as new data comes in?

  • @machomanrandysavage3788
    @machomanrandysavage3788 5 лет назад +1

    Is there a way to consume json formatted date into power by via just the URL? Meaning, Like Odata feed, provide a URL and expose data to power bi which is in jason format? Cant seem to make this happen.

  • @bonsai_mad8139
    @bonsai_mad8139 6 лет назад +2

    Never come across JSON in PBI. If I do, now I know what to do! Easy process.

  • @shammaalderei82
    @shammaalderei82 2 года назад

    Hi very helpful video 👍
    for my case i would like to use life data from world Bank for example how can i make it ? i would like when i do the refresh the power bi page it is having the updated one

  • @biancamesqueue1479
    @biancamesqueue1479 3 года назад +1

    How do you deal when (after column is transforormed .json) there’s empty columns that transform into an “error” and the other’s transform into “records”?? I’m having trouble being able to expand the Records because of the Errors :/

    • @astatine0085
      @astatine0085 3 года назад

      Having same problem. My JSON field is truncating in the query editor, but it shows in full, in the dashboard view. When I try to transform->JSON in query editor, it only returns 'error'. Still researching a solution, and if I find one, I will LYK.

  • @BenOastler
    @BenOastler 6 лет назад +1

    Is the icon over the O in JSON, the Black Sun monument in Seattle?

    • @GuyInACube
      @GuyInACube  6 лет назад

      I'm actually not sure. I tried to find the answer but couldn't find one.

  • @NCITPro
    @NCITPro 6 лет назад

    Great tip! If you interact with APIs, you are sure to need a way to parse JSON responses.

  • @aichayahya6759
    @aichayahya6759 5 лет назад

    Hi thanks for this tuto , i have two seperate object json each object has his attribues. But there is a one common data between them to create a link between them . So how can i create a view to display the data of both json object on a one json object by selecting the right one.

  • @avilajalfredo
    @avilajalfredo 4 года назад

    Hi Gyinacube! if you are free to decided, What do you prefer to fill data in a report? Direct connetion with azure database or use a Rest API?

  • @Khdkss
    @Khdkss 2 года назад

    Is there any way to fetch data as json from power bi to angular using rest api

  • @adamsabourin9416
    @adamsabourin9416 4 года назад

    I dont see an "expand" button on my JSON column header that appeared when you did it. Is that somewhere else now?

  • @Digi_Blocks
    @Digi_Blocks 3 месяца назад

    Is there any way to get the JSON of any visuals.

  • @jaypee6372
    @jaypee6372 4 года назад

    I have an api that returns a json data how can i handle that it only displays "message", "firstPageUri", "nextPageUri", "lastPageUri" and "page". How to import it from web and display it in table?
    thanks,

  • @tradetalkacademy3326
    @tradetalkacademy3326 2 года назад

    Very useful mate , Thanks

  • @vivekp3783
    @vivekp3783 2 года назад

    exactly what I needed
    Thanks

  • @jheynerlopezhurtado8680
    @jheynerlopezhurtado8680 Месяц назад

    Thanks a lot ;) Excellent tip ;)

  • @sherinjose2
    @sherinjose2 4 года назад

    Thank you..but i have a connection with direct query and this method is actually restrictred for direct query but works weel for import data.how can i use json data from table and use in power bi if my connection is direct query ??

  • @gadgetara
    @gadgetara 6 лет назад +1

    The problem arises when there are multiple json files and I want to combine them in power bi desktop. I have 6 different categories of json and each category has 3 or 4 json files to combine. Power BI Desktop doesn't help in this case. It's very cumbersome to combine them. Do you know of a good way to combine json files before we import them into power bi?

    • @ThePowerUser
      @ThePowerUser 6 лет назад +1

      Hey! I'd highly encourage you to post your full scenario with sample files on the official Power Query forum on the technet site. The solution it's easier than what you can possibly imagine :)

    • @GuyInACube
      @GuyInACube  6 лет назад

      I agree. It should be doable. You can easily merge/append different queries within Power Query. Not sure if you have tried that route.

  • @StefanBauer
    @StefanBauer Год назад

    Thanks work great in Excel too.

  • @keithchai8566
    @keithchai8566 4 года назад

    I hit issues when I am parsing a list of json records in power bi, it is loading very long for >20 minutes of waiting time. Is this the expected outcome from the column expansion? It is consisting of over 700k records in the json list.

  • @muzammilkarajgi7507
    @muzammilkarajgi7507 Год назад

    I have json link which refresh every hour and generate data how can I integrate with powerbi and how can I save data ? Please guide

  • @hsetin
    @hsetin 2 года назад

    Hi Folks, How can i use "or " command in API data extraction. I can easily use "&" to filter from multiple columns (for eg: select rows with Value "Canada" in Country_column, & value "Hockey" in Sports_column= api/reporting/request?Country=Canada&Sport=Hockey). But I do not know what syntax will I use for selecting two values in the same column. For eg: if I want data for both USA and Canada in Country Column?? (I tried " ; " , "or" and parenthesis, nothing worked!!)

  • @Pseudo___
    @Pseudo___ 6 лет назад

    can you go in reverse easily? like if got a couple tables with list/records and properties i want transform into a json format

  • @KESHAVMURTHYN
    @KESHAVMURTHYN 3 года назад

    There is no step called parse json in direct query, I need to do this step in direct query mode. Please help me with it

  • @BrExodusZoneDayzServers
    @BrExodusZoneDayzServers 4 года назад

    Very good my friend!!!

  • @adamleadbetter5206
    @adamleadbetter5206 4 года назад

    Brilliant tutorial, thank you!

  • @varunahlawat9013
    @varunahlawat9013 Год назад

    Can't we just pull the data in from an API as JSON format(where it's not just a single key valued pair, but multiple nested keys & values) and make a report for that?

  • @prasanjitswain17
    @prasanjitswain17 4 года назад

    is there a way we can automate the JSON file INTO bar/graphs in POwer BI

  • @okeomslax26
    @okeomslax26 6 лет назад

    You are a life saver man wow that was great

  • @debbielicious1
    @debbielicious1 6 лет назад +1

    Hi Adam,
    Please are we able to get JSON from a web API. I tried getting the latitude and longitude of an address data from the web but the API outputs the data in JSON. What I wanted to do was to write a function in power BI to parse the address as a parameter into the API call so each row gets automatically populated with the Lat and long data from the web. But , after several attempts and research I found out that power bi is not able to interpret this component. It always comes up with an error message but when I loaded the JSON file to my local drive the works using the JSON data connector . This is not what I want cos there's lots of addresses and I just want to use the web data connector to call the API. Please do you have any video that addresses this issue or can you make one.
    Thanks ever so much!

    • @GuyInACube
      @GuyInACube  6 лет назад

      You definitely can get JSON from a Web API. I have done demos of that with a Star Wars rest api where it converts web.contents into JSON.Document. From there, you can expand the contents. Very similar to what was done here. When I used the Get Data > Web, and put in the REST API URL, Power Query automatically wrapped it in JSON.Document because the response was of the JSON content type. I'm not sure what you are calling, but you could do it manually also.

    • @debbielicious1
      @debbielicious1 6 лет назад

      Guy in a Cube thanks a lot for the prompt response. Please can you send me the link to the video. Thanks ever so much.

  • @mohammedamir4537
    @mohammedamir4537 5 лет назад

    can we live streamed a data into power bi service using above method..like JSON value will keep on updating in single cell and then we need to interact stream dataset, created in power bi service with value in excel which is being keep on updating on its own

    • @GuyInACube
      @GuyInACube  5 лет назад

      You can mashup data. Reports aren't streamed though, so the data would need to be historical somewhere that the report would pull from. Dashboard tiles can be streaming.

  • @jamesajayi1315
    @jamesajayi1315 5 лет назад

    After I transform it not giving me any data to select what do you think it the problem

  • @danielnascimento3890
    @danielnascimento3890 5 лет назад

    Hey !! I'm Brazilian but even I could understand you pretty well, and regards connection between Plataforms I would like to know if if it's possible to link Firebase and Power BI, and I think it is since they export Json files! But my intention is connecting them ! it would be awesome if so !! Thank you mister

  • @chrislam8442
    @chrislam8442 6 лет назад

    Hi, great video! Just one question: is performance going to be an issue with bigger data sets? e.g. when converting json-data in a mysql database with millions of records? Wouldn't it be better to actually parse the jsondata into separate tables in this case?

    • @GuyInACube
      @GuyInACube  6 лет назад +1

      The more work that has to be done on the Mashup Engine side, the more performance overhead you will have. If you have a way of pre-processing that before you get to Power BI, that may perform better. As with all things, you would need to test it to see what works better.

    • @chrislam8442
      @chrislam8442 6 лет назад

      All right, thank you for your prompt answer! Your video has helped me a lot and I was able to visualize data rather quickly in Power BI! (albeit with a small data set.) I'll look into pre-processing the data first.

  • @robertburke3450
    @robertburke3450 3 года назад

    is there a drill down JSON file for DMA?!?!? I need one bad!!!

  • @mathew9665
    @mathew9665 6 лет назад +1

    Nice one Adam

  • @webparts360appstudio8
    @webparts360appstudio8 4 года назад

    This function is no longer working (changed) - instead after I transform it to JSON - it asked me an option to expand to new roles or to extract values - both of which doesn't work anymore :(

  • @biwaroBozant
    @biwaroBozant 6 лет назад

    Hi Adam, May you make a video about working with sdmx-json in power bi. For example i am try to work with OECD.Stat Developer API to import some data to Power BI but it is not working. Something is going wrong with me. Thanks

  • @terryliu3635
    @terryliu3635 4 года назад

    This is super easy!

  • @Sarabjitsethi
    @Sarabjitsethi 6 лет назад

    Is there any way to hide the see records option in Matrix visualization of POWER BI?

    • @GuyInACube
      @GuyInACube  6 лет назад

      It cannot be done for specific types of visuals, or even individual visuals. You can hide the header bar for all visuals within a report in Power BI Desktop by enabling the report setting "Hide the visual header in reading view". When you publish that to the Power BI service, it won't show the bar with the ellipses that has the Show Data option in it. This would affect all visuals within the report.

  • @harriselliott9409
    @harriselliott9409 6 лет назад

    How does one loop a folder of JSON files though and combine?

  • @magicdimension6073
    @magicdimension6073 5 лет назад

    Hey! How may I get data from .json?

  • @annjanetteiguico8309
    @annjanetteiguico8309 4 года назад

    hello I am having error when refreshing my query, "Expression.Error: The column 'Column1' of the table wasn't found.
    "

    • @GuyInACube
      @GuyInACube  4 года назад

      Not a whole lot of info to go on there. From a general stand point, when I searched for that error, I got a lot of hits. Have you tried going through any of those to see if it points you in the right direction?

  • @mrsamirbihari
    @mrsamirbihari 5 лет назад +1

    Hi Guys ..your videos are wonderful.Can you please guide me how I can extract data from YAML file . I tried using transform via JASON and parse via JASON in power query buit its not working .Can you please guide..

    • @GuyInACube
      @GuyInACube  5 лет назад

      Appreciate the kind words Samir! I will put it on the list, but don't know when it would be out.

  • @KarineLago
    @KarineLago 6 лет назад +3

    Great, Adam! But hey, warning! Pieblanc is at risk (3:58). Get him out of the risk haha ;-)

    • @GuyInACube
      @GuyInACube  6 лет назад +1

      hahaha thanks Karine! He is definitely at risk! ;)

  • @SolutionsAbroad
    @SolutionsAbroad 4 года назад

    Wow that JSON button was hiding in plain sight!

  • @artemakchurin9114
    @artemakchurin9114 4 года назад

    Freakin' marvellous!

  • @Silencioraul
    @Silencioraul 4 года назад

    OH MY GOD !!! ITS VERY EASY !!!!

  • @ele287
    @ele287 4 года назад

    Thanks ! It's saving my connection Power BI/Snowflake :D

  • @tinkuraj9715
    @tinkuraj9715 3 года назад

    How to work with JSON while using live connection

  • @alamkhan4062
    @alamkhan4062 2 года назад

    loading blocked by failures with other queries while refreshing API data

  • @saurabhbd2411
    @saurabhbd2411 6 лет назад

    Thanks, this solution worked

  • @DanielSvendsen86
    @DanielSvendsen86 6 лет назад +1

    More importantly.. Could you point me in the direction of the Deadpool picture you use as a background on your second monitor? It looks really cool, and would like to use it myself. :D

    • @GuyInACube
      @GuyInACube  6 лет назад

      haha :) there was some wallpaper site I found that I pulled it off of. That was a while ago and I don't remember what it was.

  • @syednayyar
    @syednayyar 5 лет назад

    Awesome 👍👍👍😊

  • @rradunz
    @rradunz 6 лет назад

    great stuff!

  • @janejoias
    @janejoias 5 лет назад +1

    Thank you!

    • @GuyInACube
      @GuyInACube  5 лет назад +1

      Most welcome! Thanks for watching Karen. 👊

  • @prozackpills
    @prozackpills 2 года назад

    what do I do if my JSON has Lists? 😕

  • @wellingtonroa9298
    @wellingtonroa9298 4 года назад

    Amazon video. How I do that’s in Power BI web?

  • @MarkDengler
    @MarkDengler 5 лет назад

    Is there a video on how to source Azure Cognitive Services?

    • @GuyInACube
      @GuyInACube  5 лет назад

      We don't have anything on Azure Cognitive Services. What specifically are you looking for?

  • @geojbarros
    @geojbarros 6 лет назад +1

    Peace of cake. Thank you guys...

    • @GuyInACube
      @GuyInACube  6 лет назад

      Awesome! Thanks for watching.

  • @Wegetowaly
    @Wegetowaly 4 года назад

    soooooo good!

  • @bharathraj4545
    @bharathraj4545 4 года назад

    Iam getting a error while parseing the data

  • @yangmyfly
    @yangmyfly 5 лет назад

    why cannot allow just read ndjson

  • @Sarabjitsethi
    @Sarabjitsethi 6 лет назад +1

    Hey guys ,, can i join you ? :) you are making the developer life easy

    • @GuyInACube
      @GuyInACube  6 лет назад

      haha love it! We don't have a spot right now though. Keep crushing it though. 👊

    • @Sarabjitsethi
      @Sarabjitsethi 6 лет назад

      Guy in a Cube thanks for replying..#crushingcontinue

  • @sushantjadhav3011
    @sushantjadhav3011 5 лет назад

    Can we get the details of a chart like dimension and measures in json using power bi api?

  • @tedvedia9436
    @tedvedia9436 6 лет назад +1

    Awesome

    • @GuyInACube
      @GuyInACube  5 лет назад

      Thanks for watching Teodoro!

  • @nicksharma8043
    @nicksharma8043 5 лет назад

    awesome

  • @utpalkantkumar3341
    @utpalkantkumar3341 6 лет назад

    What I am wrong doing while calling rest API in power Bi ?
    Because I am getting JOSN Response but To MUCH Column ,each key and Value pair's coming in Columns by ,
    And I know it should be come only one column
    ?

  • @lydialim1993
    @lydialim1993 4 года назад

    This. This is the sort of thing where PBI totally defeats Tableau. PBI can handle almost any kind of data you throw at it. The year now is 2020, and Tableau STILL does not have any JSON parser function!!!!

  • @jonkrane6762
    @jonkrane6762 2 года назад

    Not really helpful unless we can group the new records back to t original record and then make the json data into normalized tables.

  • @writetoprithvi
    @writetoprithvi 3 года назад

    Right click to transform to json 😀

  • @stephanweaver1960
    @stephanweaver1960 3 года назад

    ..you'll find it when you create a table within PBI..

  • @dianal3627
    @dianal3627 4 года назад

    This is not what my data looks like when i connect to it in power bi.

  • @rdildev6759
    @rdildev6759 5 лет назад

    Awful! Need to show how you input JSON not CSV with JSON inside! ta