Pushing Log Analytics Workspace tables into SQL databases

Copper Contributor

Hi,

I am trying to push Log Analytics data into PowerBI with a custom refresh schedule. Since this is not already supported by PowerBI I am trying to push it into a SQL database instead which is then connected to PowerBI. Is there a specific script I can run to achieve this and then use a task scheduler to push the data regularly? Suggestions for a different approach will also be helpful.

 

Thank You

1 Reply

Hi @Mitali645 

Log Analytics and Power BI work really well together.

All you need to do to use LA data in Power BI is:

1. Compose the query you want to use in Power BI in Log Analytics.

2. After you are happy with your query click "export" and use the 'export to Power BI (M query) option to create a Power BI friendly version of your query.

3. Open Power BI desktop

4. Click "get data"

5. Select "blank query" from the Get data options

6. Click "Advanced Editor" and paste the content exported from Log Analytics in the window that opens

7. Click "ok" - note - you may have to authenticate with Azure at this point

You are all set! Power BI will now run the query and get the Log Analytics data into your report!
You may publish the Power BI report to Powerbi.com and set a refresh schedule to your liking.

Hope this helped.

P.S

If you still want to - you can also integrate Log Analytics with SQL.

I usually use Microsoft Flow or Azure Logic app to create a flow that runs a query in LA and writes it to SQL - however, I think it will be overkill for what you are trying to achieve here.

R