Jun 29 2023 02:23 PM
How do I see all queries run between 2:00 am and 2:30 am on a SQL Server? Am I also able to see the query text that was used?
Jun 29 2023 11:04 PM
@HDale17 , if you haven't implemented a query audit, then it's not really possible to get queries afterwards.
In newer SQL Server version you can enable the "Query Store" feature, see
Monitor performance by using the Query Store - SQL Server | Microsoft Learn