Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
8 years ago

Store old data upon refresh?

So I have a historical table that has data from years past, but then I have another table that has a live connection to download the latest daily data. 

 

How can I structure my query to append the daily data to the historical table upon refresh so that the historical table will keep growing with each day's data when the model is refreshed daily?

 

Is this possible?

8 Replies

  • Hi Anonymous,

     

    => I have a historical table that has data from years past, but then I have another table that has a live connection to download the latest daily data. 

     

    Can I understand as you have two datasets? One is the past data and one is daily data. If you want to combine the two queries into one. You can go to Edit Queries and try Append Queries option. Then publish this new report to Power BI Service, set scheduled refresh to update the daily data.

     

    Thanks,
    Xi Jin.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Yes, I know how to append the query to the histroical table, however, that is not my issue. Let me show an example:

       

      My historical dataset is a static excel file that has daily data from January 1, 2018 to March 21, 2018. My "live" dataset is connected to a webpage that updates daily. I can setup my historical dataset to append the live dataset to the bottom so that today's data (March 22) will then be included in the historical dataset. However, tomorrow (March 23) when I go to refresh my live dataset, the historical dataset will append the March 23 data, but the March 22 data will be gone. So now my dataset will have data from January 1, 2018 - March 21, 2018 and also March 23, 2018, but March 22 will not be present.

       

      Is there a way to append the daily data to a historical dataset and keep it there?

      • katiejroberts's avatar
        katiejroberts
        Frequent Visitor

         


        Anonymous wrote:

        Yes, I know how to append the query to the histroical table, however, that is not my issue. Let me show an example:

         

        My historical dataset is a static excel file that has daily data from January 1, 2018 to March 21, 2018. My "live" dataset is connected to a webpage that updates daily. I can setup my historical dataset to append the live dataset to the bottom so that today's data (March 22) will then be included in the historical dataset. However, tomorrow (March 23) when I go to refresh my live dataset, the historical dataset will append the March 23 data, but the March 22 data will be gone. So now my dataset will have data from January 1, 2018 - March 21, 2018 and also March 23, 2018, but March 22 will not be present.

         

        Is there a way to append the daily data to a historical dataset and keep it there?


         

        Hi nobodyukno, 

         Did you ever end up finding any sort of solution to this?  I'm going through the same issue right now and not ready to give up just yet... haha.  Please let me know - thanks very much.

  • I think you can try the 'Include in report refresh' option. This needs to be setup while you are creating the table.
    1. Create/load a table1 (query) with historic data. 

    2 .Create/load another table2 (query) with current data.
    3. On table1 - rightclick - uncheck 'Include in report refresh'. Would advise uncheck 'Enable load', as table1 will only be used for append.

    4. Append table1 & table2

     

    Now each time you refresh table1 will not get refreshed & table2 will bring in new data.

    It is not dynamic, which I also want an option, you may want to transfer table2 data manually at source for any data to be termed as historic.

     

    'Include in report refresh' prevent refresh of table each time.
    Read more here : https://learn.microsoft.com/en-us/power-bi/connect-data/refresh-include-in-report-refresh