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

Data Snapshots

I am trying to figure out how to go about taking a snapshot of some data. We keep a daily count of our active companies, but things are constantly changing in our database so the numbers always change. For instance, today I can get the exact active client count for 2/8/2018 which is 4,309. If I open up my PBI report in a few weeks, or even days, and want to look back to see what the active client count was on 2/8/2018, it would no longer read 4,309, but some other random number that could either be higher or lower since the data is constantly changing in our SQL database. Is there a way that each day I can take a snapshot of the date and client count on that day and have it stored in some additional table to reference? We are attempting to record customer retention and I just want the numbers as accurate as possible. Thanks!

1 ACCEPTED SOLUTION
v-fengyz-msft
Helper I
Helper I

@Anonymous

 

Power BI does not have incremental load at present. This means that if you try to timestamp something at the time of query load, you will get updated values for the timestamp when it is refreshed.

 

Three options for your reference:

 

1. Storing and using information from a dynamic data source using PBI desktop

 

2. Use R script: auto export of data

 

3. Create a Trigger on source table to insert rows to your DataChangeLog table as soon as the data updated from source table in your database. Colde looks like below:

 

create trigger triggername On sourcetable

for update

as

insert into destinationtable (column) select column from TriggerTest1

Go

 

You can vote the idea: Allow for point-in-time snapshots for reports/dataset

 

Regards,

Pirlo Zhang 

View solution in original post

5 REPLIES 5
v-fengyz-msft
Helper I
Helper I

@Anonymous

 

Power BI does not have incremental load at present. This means that if you try to timestamp something at the time of query load, you will get updated values for the timestamp when it is refreshed.

 

Three options for your reference:

 

1. Storing and using information from a dynamic data source using PBI desktop

 

2. Use R script: auto export of data

 

3. Create a Trigger on source table to insert rows to your DataChangeLog table as soon as the data updated from source table in your database. Colde looks like below:

 

create trigger triggername On sourcetable

for update

as

insert into destinationtable (column) select column from TriggerTest1

Go

 

You can vote the idea: Allow for point-in-time snapshots for reports/dataset

 

Regards,

Pirlo Zhang 

@v-fengyz-msft

 

Can you please provide an example of option 3 with sample tables? 

 

Thanks! 

 

 

@v-fengyz-msft
I would also love to know more about the create trigger. I'm assuming it's M written into the advanced editor. Is there any documentation you could direct us too.

@v-fengyz-msft
I would also love to know more about the create trigger. I'm assuming it's M written into the advanced editor. Is there any documentation you could direct us too.

I'd like to follow your example for option 3.

 

Can you please show step by step directions for how to add like you would do it using example tables?

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.