Forum Discussion
Generate Missing Data via Script
For generating a table of dates, take a look at the CALENDARAUTO() DAX function. This creates a Calculated Table across all the date range in your model.
Then you can add a column to that table that pulls the relevant Exchange Rate for the dates that have a value.
You could fill in the remaining Exchange Rate values by using the a DAX calculation like this:
FullExchangeRate =
CALCULATE(
LASTNONBLANK(Query1[Exchange Rate], TRUE()) ,
CALCULATETABLE( DATESYTD(Query1[Date]) ,
DATESBETWEEN(Query1[Date],
BLANK(),
LASTDATE(Query1[Date])
) ,
ALL(Query1)) ,
ALL(Query1)
)
There might be a more efficient way to do that, but it'll work!