Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

How to model queries in Power BI for daily append of new data instead of overwriting

Hi,

I'm trying to build a simple report based upon data published on a website. Here is what I want to achieve

  1. This website publishes data for COVID cases in the country.
  2. The number are just the current numbers, without any time-series.
  3. I want to fetch these numbers from this website daily and build a report on top of it (with time series kind of analysis).
  4. So I fetch these numbers (Get Data > Web > URL) and get this into a query
  5. I then add a custom column with a timestmap (M's DateTime.LocalNow() fucntion) and get this data with the required timestamp.
  6. Now I want to refresh this query daily, so that I get daily results in this query.
  7. As expected, PBI simply overwritse the existing rows with new data, with the latest timestamp (my custom column).

I tried few things like:-

  1. Creating a new query and appending data to it, it doesn't seem to work, existing data gets over-written (maybe the way I have created the new query).
  2.  Explored incremental refresh, it doesn't seem to fit my use case.
  3. Tried looking at other similar posts, none seem to help me resolve this.

Questions:-

  1. Is there a simple workaround to circumvent this (point#7) and have PBI append new data instead of overwriting existing data.
  2. Am i correct on point#2 above (incremental refresh)? 

 

Appreciate any pointers. Thanks in advance!

3 REPLIES 3
FrankAT
Community Champion
Community Champion

Hi @Anonymous ,

which URL do you use to get the data?

 

Regards FrankAT

Greg_Deckler
Super User
Super User

Couple options. 

 

One, create a new query. Disable refresh on the original query. Create an Append query as New that appends the new query to the original query.

 

Or, download the files to a folder every day. Use a Folder query.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Option#1: Based upon what I could try, I could see my append query's data was also got overwritten during refresh, which I didn't want. Is it really an option? May be I didn't implement it the way it shoud have.

 

Option#2: I did some further lookup and found that this is probably the right way to do this, have my own little staging and transformation layer (add time series attribute) and then have PBI connect to this layer.

 

Thanks. 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.