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

Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers. Get Fabric certified for FREE! Learn more

Reply
nandasatria
Frequent Visitor

How to Integrate Log Analytics Workspace to Eventhouse

I need to analyze data from a Log Analytics workspace in Fabric.

Is it possible to integrate it with Eventhouse so I can run Kusto Queries from Eventhouse while the data remains in the Log Analytics workspace?

Or do we need to move the data from the Log Analytics workspace to Eventhouse? If yes, how can we do it?

Currently, I need to export the data to Blob Storage and use it in a notebook, but in that case, I cannot use KQL

 

Thanks

1 ACCEPTED SOLUTION
v-tangjie-msft
Community Support
Community Support

Hi @nandasatria ,

 

You can export the data from the Log Analytics workspace to an Azure Storage Account or Azure Event Hubs. This can be done using the Log Analytics workspace data export feature. You can then create an Eventhouse and then fetch the data from the event hub into the KQL database in the Eventhouse.

For more details, please refer:

Log Analytics workspace data export in Azure Monitor - Azure Monitor | Microsoft Learn

Create an eventhouse - Microsoft Fabric | Microsoft Learn

Get data from Azure Event Hubs - Microsoft Fabric | Microsoft Learn

 

If you prefer to continue using Blob Storage, you can set up a scheduled export from a log query using Azure Logic Apps. This method allows you to query data from a Log Analytics workspace and send it to Azure Storage.

Export data from a Log Analytics workspace to a storage account by using Logic Apps - Azure Monitor ...

 

Best Regards,

Neeko Tang

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

 

View solution in original post

6 REPLIES 6
nandasatria
Frequent Visitor

Hi @v-tangjie-msft 

That was great! I successfully stored the data from Log Analytics using Data Exporter and Event Hub to the KQL database in the Eventhouse. However, the problem is with the data structure; it is in the project fields, not parsed data. When I try to add a transformation event to expand the data, it shows an error: "Please connect this node to the upstream node with a schema before configuring it."

Is this a common issue? Do we need to manually use KQL, like using mv-expand to expand the data in the array and project for every field in the records?

Or is there another best practice to make the data more ready to use?

 

Thanks

Hi @nandasatria ,

 

The error message "Please connect this node to the upstream node with a schema before configuring it" typically indicates that the data schema is not properly defined or recognized in the transformation pipeline. This can happen when the data is not parsed correctly or when the schema is not propagated through the nodes.

 

It is recommended to use the Kusto Query Language (KQL) to parse and expand data. the “mv-expand” operator can be used to expand arrays and nested data structures. The following is an example:

   ```kusto
   let rawData = datatable (RawData: dynamic)
   [
       dynamic({"field1": "value1", "field2": ["value2a", "value2b"]}),
       dynamic({"field1": "value3", "field2": ["value2c", "value2d"]})
   ];
   rawData
   | mv-expand field2
   | project field1, field2
   ```

 

Best Regards,

Neeko Tang

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

Hi @v-tangjie-msft 

Yes, currently I use KQL to parse the data manually, but the problem is that I need to project every field, which requires a lot of effort if the table is large. Moreover, when we need to aggregate incoming data for various analyses, we have to use mv-expand and project for each field repeatedly

This is my current Event Stream Flow:

 

nandasatria_0-1738941834240.png

Is it typical for data from Event Hub to come without a schema, or is the schema from the data in Event Hub not recognized. How to make this more seamless for many aggregation ?

 

Thanks 

 

Hi @nandasatria ,

 

When data is sent to Event Hub, it is typically in a raw format (e.g., JSON, Avro, or plain text). Event Hub itself does not enforce or recognize a schema; it simply acts as a message broker. As a result:

The data may arrive in a nested or semi-structured format (e.g., JSON arrays or objects).

Eventhouse (KQL database) does not automatically infer the schema unless explicitly defined during ingestion or transformation.

This is why you often need to manually parse and flatten the data using KQL functions like parse_json, mv-expand, and extend.

 

You can try to use Azure Data Factory to transform the data and write it to Eventhouse in a flattened format or use a notebook to preprocess the data and write it back to Eventhouse.

 

Best Regards,

Neeko Tang

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

Thanks for your help @v-tangjie-msft 

v-tangjie-msft
Community Support
Community Support

Hi @nandasatria ,

 

You can export the data from the Log Analytics workspace to an Azure Storage Account or Azure Event Hubs. This can be done using the Log Analytics workspace data export feature. You can then create an Eventhouse and then fetch the data from the event hub into the KQL database in the Eventhouse.

For more details, please refer:

Log Analytics workspace data export in Azure Monitor - Azure Monitor | Microsoft Learn

Create an eventhouse - Microsoft Fabric | Microsoft Learn

Get data from Azure Event Hubs - Microsoft Fabric | Microsoft Learn

 

If you prefer to continue using Blob Storage, you can set up a scheduled export from a log query using Azure Logic Apps. This method allows you to query data from a Log Analytics workspace and send it to Azure Storage.

Export data from a Log Analytics workspace to a storage account by using Logic Apps - Azure Monitor ...

 

Best Regards,

Neeko Tang

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

 

Helpful resources

Announcements
MarchFBCvideo - carousel

Fabric Monthly Update - March 2025

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

March2025 Carousel

Fabric Community Update - March 2025

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

"); $(".slidesjs-pagination" ).prependTo(".pagination_sec"); $(".slidesjs-pagination" ).append("
"); $(".slidesjs-play.slidesjs-navigation").appendTo(".playpause_sec"); $(".slidesjs-stop.slidesjs-navigation").appendTo(".playpause_sec"); $(".slidesjs-pagination" ).append(""); $(".slidesjs-pagination" ).append(""); } catch(e){ } /* End: This code is added by iTalent as part of iTrack COMPL-455 */ $(".slidesjs-previous.slidesjs-navigation").attr('tabindex', '0'); $(".slidesjs-next.slidesjs-navigation").attr('tabindex', '0'); /* start: This code is added by iTalent as part of iTrack 1859082 */ $('.slidesjs-play.slidesjs-navigation').attr('id','playtitle'); $('.slidesjs-stop.slidesjs-navigation').attr('id','stoptitle'); $('.slidesjs-play.slidesjs-navigation').attr('role','tab'); $('.slidesjs-stop.slidesjs-navigation').attr('role','tab'); $('.slidesjs-play.slidesjs-navigation').attr('aria-describedby','tip1'); $('.slidesjs-stop.slidesjs-navigation').attr('aria-describedby','tip2'); /* End: This code is added by iTalent as part of iTrack 1859082 */ }); $(document).ready(function() { if($("#slides .item").length < 2 ) { /* Fixing Single Slide click issue (commented following code)*/ // $(".item").css("left","0px"); $(".item.slidesjs-slide").attr('style', 'left:0px !important'); $(".slidesjs-stop.slidesjs-navigation").trigger('click'); $(".slidesjs-previous").css("display", "none"); $(".slidesjs-next").css("display", "none"); } var items_length = $(".item.slidesjs-slide").length; $(".slidesjs-pagination-item > button").attr("aria-setsize",items_length); $(".slidesjs-next, .slidesjs-pagination-item button").attr("tabindex","-1"); $(".slidesjs-pagination-item button").attr("role", "tab"); $(".slidesjs-previous").attr("tabindex","-1"); $(".slidesjs-next").attr("aria-hidden","true"); $(".slidesjs-previous").attr("aria-hidden","true"); $(".slidesjs-next").attr("aria-label","Next"); $(".slidesjs-previous").attr("aria-label","Previous"); //$(".slidesjs-stop.slidesjs-navigation").attr("role","button"); //$(".slidesjs-play.slidesjs-navigation").attr("role","button"); $(".slidesjs-pagination").attr("role","tablist").attr("aria-busy","true"); $("li.slidesjs-pagination-item").attr("role","list"); $(".item.slidesjs-slide").attr("tabindex","-1"); $(".item.slidesjs-slide").attr("aria-label","item"); /*$(".slidesjs-stop.slidesjs-navigation").on('click', function() { var itemNumber = parseInt($('.slidesjs-pagination-item > a.active').attr('data-slidesjs-item')); $($('.item.slidesjs-slide')[itemNumber]).find('.c-call-to-action').attr('tabindex', '0'); });*/ $(".slidesjs-stop.slidesjs-navigation, .slidesjs-pagination-item > button").on('click keydown', function() { $.each($('.item.slidesjs-slide'),function(i,el){ $(el).find('.c-call-to-action').attr('tabindex', '-1'); }); var itemNumber = parseInt($('.slidesjs-pagination-item > button.active').attr('data-slidesjs-item')); $($('.item.slidesjs-slide')[itemNumber]).find('.c-call-to-action').attr('tabindex', '0'); }); $(".slidesjs-play.slidesjs-navigation").on('click', function() { $.each($('.item.slidesjs-slide'),function(i,el){ $(el).find('.c-call-to-action').attr('tabindex', '-1'); }); }); $(".slidesjs-pagination-item button").keyup(function(e){ var keyCode = e.keyCode || e.which; if (keyCode == 9) { e.preventDefault(); $(".slidesjs-stop.slidesjs-navigation").trigger('click').blur(); $("button.active").focus(); } }); $(".slidesjs-play").on("click",function (event) { if (event.handleObj.type === "click") { $(".slidesjs-stop").focus(); } else if(event.handleObj.type === "keydown"){ if (event.which === 13 && $(event.target).hasClass("slidesjs-play")) { $(".slidesjs-stop").focus(); } } }); $(".slidesjs-stop").on("click",function (event) { if (event.handleObj.type === "click") { $(".slidesjs-play").focus(); } else if(event.handleObj.type === "keydown"){ if (event.which === 13 && $(event.target).hasClass("slidesjs-stop")) { $(".slidesjs-play").focus(); } } }); $(".slidesjs-pagination-item").keydown(function(e){ switch (e.which){ case 37: //left arrow key $(".slidesjs-previous.slidesjs-navigation").trigger('click'); e.preventDefault(); break; case 39: //right arrow key $(".slidesjs-next.slidesjs-navigation").trigger('click'); e.preventDefault(); break; default: return; } $(".slidesjs-pagination-item button.active").focus(); }); }); // Start This code is added by iTalent as part of iTrack 1859082 $(document).ready(function(){ $("#tip1").attr("aria-hidden","true").addClass("hidden"); $("#tip2").attr("aria-hidden","true").addClass("hidden"); $(".slidesjs-stop.slidesjs-navigation, .slidesjs-play.slidesjs-navigation").attr('title', ''); $("a#playtitle").focus(function(){ $("#tip1").attr("aria-hidden","false").removeClass("hidden"); }); $("a#playtitle").mouseover(function(){ $("#tip1").attr("aria-hidden","false").removeClass("hidden"); }); $("a#playtitle").blur(function(){ $("#tip1").attr("aria-hidden","true").addClass("hidden"); }); $("a#playtitle").mouseleave(function(){ $("#tip1").attr("aria-hidden","true").addClass("hidden"); }); $("a#play").keydown(function(ev){ if (ev.which ==27) { $("#tip1").attr("aria-hidden","true").addClass("hidden"); ev.preventDefault(); return false; } }); $("a#stoptitle").focus(function(){ $("#tip2").attr("aria-hidden","false").removeClass("hidden"); }); $("a#stoptitle").mouseover(function(){ $("#tip2").attr("aria-hidden","false").removeClass("hidden"); }); $("a#stoptitle").blur(function(){ $("#tip2").attr("aria-hidden","true").addClass("hidden"); }); $("a#stoptitle").mouseleave(function(){ $("#tip2").attr("aria-hidden","true").addClass("hidden"); }); $("a#stoptitle").keydown(function(ev){ if (ev.which ==27) { $("#tip2").attr("aria-hidden","true").addClass("hidden"); ev.preventDefault(); return false; } }); }); // End This code is added by iTalent as part of iTrack 1859082
Top Solution Authors