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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
mrtnhd
Frequent Visitor

Lakehouse Shortcut to Data Warehouse not working in notebooks after refresh of SQL Endpoint

I am using data warehouse tables in notebooks. My initial setup was to attach the warehouse to the notebook and read the table. This is no longer possible and I am therefore creating lakehouse schema shortcut (using preview feature with lakehouse schemas) to data warehouse schema. This setup has been working until I started refreshing the sql endpoints of the lakehouse shortcuts (because they otherwise have outdated data or are not working when using sql endpoint) with 
uri = f"/v1.0/myorg/lhdatamarts/{sqlendpoint_id}"
payload = {"commands":[{"$type":"MetadataRefreshExternalCommand"}]}
response = client.post(uri, json=payload)

Now I get this error: [DELTA_FEATURES_PROTOCOL_METADATA_MISMATCH] Unable to operate on this table because the following table features are enabled in metadata but not listed in protocol: invariants.

 

The sql endpoint of the lakehouse shortcut works fine. I can also preview the data in the lakehouse (not sql endpoint). I have tried reading with pyspark and t-sql in the notebook. They both throw the same error.

 

Any idea how to fix this?

1 ACCEPTED SOLUTION
MonicaCVL
Advocate I
Advocate I

Hi @mrtnhd ,

 

If your goal is to read/write data from/to the warehouse then check this spark connector for Datawarehouse!
https://learn.microsoft.com/en-us/fabric/data-engineering/spark-data-warehouse-connector?tabs=pyspar...

You don't have to create shortcuts on top of your warehouse tables!
Hope this is helpful, If so please accept this answer!

View solution in original post

2 REPLIES 2
MonicaCVL
Advocate I
Advocate I

Hi @mrtnhd ,

 

If your goal is to read/write data from/to the warehouse then check this spark connector for Datawarehouse!
https://learn.microsoft.com/en-us/fabric/data-engineering/spark-data-warehouse-connector?tabs=pyspar...

You don't have to create shortcuts on top of your warehouse tables!
Hope this is helpful, If so please accept this answer!

Thank you so much! That seems to solve my issue. It works fine in at least one notebook.  

Helpful resources

Announcements
Fabric July 2025 Monthly Update Carousel

Fabric Monthly Update - July 2025

Check out the July 2025 Fabric update to learn about new features.

July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.