Azure SQL Database – Error Logs?

Ok, so Azure SQL doesn’t really have its own error log based somewhere on a machine within \\MSSQL\Log directory but the closest thing you will get is a system catalog view called sys.event_log which is very useful. It will get you information about all sort of event types such as:

  • Successful connections
  • Failed connections
  • Throttling issues
  • Blocked by firewall attempts
  • Connection termination

I used this code against the master database.


SELECT database_name,start_time,end_time,event_type, severity =
CASE Severity
WHEN 0 THEN 'Informational'
WHEN 1 THEN 'WARNING'
WHEN 2 THEN 'ERROR'
ELSE 'No Data Avaliable'
END,
description
FROM sys.event_log

ORDER BY start_time DESC

So here I was just looking for errors relating to login failures.

errorlogs

 

4 thoughts on “Azure SQL Database – Error Logs?

  1. Pingback: Dew Drop – April 8, 2020 (#3171) | Morning Dew

  2. Pingback: Https azure log analytics login failures sql databases Portal Guide Instructions Help - centtip.com

Leave a Reply