Sending MS SQL data to log analytics workspace

Copper Contributor

Hi everyone,

 

Is it possible to send structured data from MS SQL to the log analytics workspace? (like the data in the form of rows and tables)

 

Thanks,

Nikitha

1 Reply

@nicheem To send structured data from MS SQL to Azure Log Analytics, you can use the Log Analytics Data Collector API. The Data Collector API allows you to send log data to the Azure Log Analytics workspace using HTTP or HTTPS. You can send structured data in the form of JSON, which can include tables and rows.

 

Create SQL queries to extract the desired data from MS SQL and convert it to JSON format. You can use built-in functions like FOR JSON PATH to generate the JSON output.

 Use the Log Analytics Data Collector API to send the JSON data to the Azure Log Analytics workspace. The data will be automatically parsed and indexed by Log Analytics.

Please "Accept as Answer" if it helped so it can help others in community looking for help on similar topics.