How to find when was the last time a user logged in to Azure Databricks?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-25-2025 04:49 AM
Hi,
I am asked to prepare a report on Azure Databricks usage in our company. Most metadata I need, like a list of users, workspaces, users rights on workspaces etc. I already have, but I do not know how to determine when the last time was a user logged in to an Azure Databricks workspace. Any suggestions would be highly appreciated.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-25-2025 05:53 AM
I'm not sure, but have you tried checking in system catalog tables ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-27-2025 03:13 AM - edited 10-27-2025 03:14 AM
Hi @schluckie you can check using a query like the one below and just change the ip address to match your conventions, or remove it entirely.
SELECT event_time, user_identity.email, source_ip_address, action_name, response.status_code
FROM system.access.audit
WHERE action_name IN ('login', 'logout', 'createToken', 'deleteToken')
AND (response.status_code >= 400 OR source_ip_address NOT LIKE 'xx.%')
AND event_date >= current_date() - INTERVAL 7 DAYS
ORDER BY event_time DESC