Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago

How to refresh data source from Datalake to get new schema

My ex-teammate built a Power BI dashboard with Datalake as datasource .

The datasource is querying with below script:

 

= fn_ReadDeltaTable(
AzureStorage.DataLake(
"https://myadls.dfs.core.windows.net/public/data/MyDeltaTable.delta",
[HierarchicalNavigation = false]))

 

 

We need to refresh this datasource because the Delta table have added and remove some columns. I want to reflect the change on Power BI dashboard. How could I refresh the schema?

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

    To refresh the architecture of the Power BI dashboard after making changes in the Delta table, you can perform the following steps:

    Explicitly update the schema:
    You can explicitly update the schema of a Delta table by adding new columns, reordering existing columns, or renaming columns using a Data Definition Language (DDL) statement.
    For example, to add a column, use the following SQL command:

    ALTER TABLE table_name ADD COLUMNS (col_name data_type [COMMENT col_comment] [FIRST|AFTER colA_name], ...)

    Below is the official link will help you:

    Update Delta Lake table schema - Azure Databricks | Microsoft Learn

    Best Regards,

    Xianda Tang

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • Anonymous's avatar
      Anonymous
      Not applicable

      The article you quoted above is how to update datalake schema, which I have already done. The problem is how to reflect the schema change in Power BI. 

       

      For instance, I have added a new column "columnA" in Datalake. But in Power BI Dashboard column A still exist. There is no refresh button for the Datalake source.