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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
pmscorca
Kudo Kingpin
Kudo Kingpin

Retrieving the KQL definition of a materialized view in the KQL database explorer

Hi,

I've need to modify some KQL materialized views, but I cannot find how I could retrieve the related KQL code inside the KQL database explorer.

Does it exist a manner to retrieve the definition of a KQL materialized view, please? Thanks

1 ACCEPTED SOLUTION
datacoffee
Super User
Super User

You can use the 

 

.show materialized-view <viewname>

 

to get the KQL statement behind the view and also status of the view.

 

Also read more here: .show materialized-view command - Kusto | Microsoft Learn


If you find this reply to help with your problem, please consider hitting the accept button...
----------------
Blog: https://dcode.bi
KQL ref guide: https://aka.bi/kql
LinkedIn: https://aka.bi/follow

View solution in original post

5 REPLIES 5
datacoffee
Super User
Super User

You can use the 

 

.show materialized-view <viewname>

 

to get the KQL statement behind the view and also status of the view.

 

Also read more here: .show materialized-view command - Kusto | Microsoft Learn


If you find this reply to help with your problem, please consider hitting the accept button...
----------------
Blog: https://dcode.bi
KQL ref guide: https://aka.bi/kql
LinkedIn: https://aka.bi/follow

Hi, ok but it is a KQL statement and not a feature of KQL database explorer.

Correct - you need to do it by code 


If you find this reply to help with your problem, please consider hitting the accept button...
----------------
Blog: https://dcode.bi
KQL ref guide: https://aka.bi/kql
LinkedIn: https://aka.bi/follow
Anonymous
Not applicable

Hi @pmscorca ,

If you want to modify your KQL materialized views, you can use this command:

.create-or-alter materialized-view

Please check this document:
https://learn.microsoft.com/en-us/kusto/management/materialized-views/materialized-view-create-or-al... 

For other commands, check these links:
Materialized views use cases - Kusto | Microsoft Learn
Materialized views - Kusto | Microsoft Learn


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

Hi, thanks for your reply.

I've already read the documentatio about create or alter a materialized view but I'd like to find a manner in the KQL database explorer to retrieve the materialized view definition like f.e. it is possible for a view in a warehouse. Thanks

Helpful resources

Announcements
December Fabric Update Carousel

Fabric Monthly Update - December 2025

Check out the December 2025 Fabric Holiday Recap!

Real Time Intelligence in a Day

Real-Time Intelligence in a Day—Free Training

Turn streaming data into instant insights with Microsoft Fabric. Learn to connect live sources, visualize in seconds, and use Copilot + AI for smarter decisions.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors
Users online (5,913)