Clear mssql cache
If you for example need to test a query against two SQL servers hardware, its a good idea to clear the cache first.This query can do this:
If you for example need to test a query against two SQL servers hardware, its a good idea to clear the cache first.This query can do this:
If you ever need to see the status of a running jobs, this TSQL can be very helpfull
If you wan to know the sync status of a always On availability group database replication, this command can be used:
To see MSSQL history Query, run this SQL query. It will show all backups between the 1 january 2021 and 1 february 2021, order by Database and then Last backup…
You can check which statements are blocked by running this
Thanks for the script to John Eisbrener – Check for new version here: https://dbaeyes.wordpress.com/2013/04/19/fully-script-out-a-mssql-database-role/
I have this problems, that if a schedule inside a Agent job, have not been started for some reason, there will be no errors about this problem. So Í have…
The function I use fn_hadr_group_is_primary from this post is a UDF (User Defined Function) that we create in the master database. The function gets an Availability Group name as an…
I need to find a way to see if the backup chain where broken. On my search I found this could script, created by “hot2use”I have found this script on…
This command, can be run on both the primary and secondary node.