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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
MontanaBlack
New Member

Keep The Existing Data In Your Power BI Dataset And Add New Data To It Using Incremental Refresh

Hi Everyone,

 

for using the incremental refresh function, I am trying to add a column to my dataset, which adds automatically the date when the upload was made and Power BI keeps the data that’s already in my dataset and add new data to it. I added the following M-Code to Power Query but I get the error message "missing identifier". 

 

let
//Find the current date and time when this query runs
CurrentDateTime = DateTimeZone.FixedUtcNow(),
//Find yesterday's date
PreviousDay = Date.AddDays(DateTime.Date(CurrentDateTime),–1),
//Put the current date and time in a new column in the table
#"Added Custom" = Table.AddColumn(#"Renamed Columns", "UTC Data Load Date", each CurrentDateTime),
#"Changed Type3" = Table.TransformColumnTypes(#"Added Custom",{{"UTC Data Load Date", type datetimezone}}),
//Add the filter required for incremental refresh
//Only return rows in this table if:
//a) The RangeStart parameter equals yesterday's date, and
//b) RangeEnd is not null (which should never be true)
#"Filtered Rows" = Table.SelectRows(#"Changed Type3", each DateTime.Date(RangeStart)=PreviousDay and RangeEnd<>null)
in
#"Filtered Rows"

1 REPLY 1
lbendlin
Super User
Super User

That's not how incremental refresh works.  Incremental Refresh expects immutable data (that won't change after it is written) and it expects RangeStart and RangeEnd to define partition boundaries. The typical usage pattern is

 

RangeStart <= [Created Date]  and [Created Date] < RangeEnd

 

You seem to be looking for a different refresh type.

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Solution Authors