Reputation
Top tag
Next privilege 100 Rep.
Edit community wikis
Badges
1 3
Newest
 Necromancer
Impact
~12k people reached

  • 0 posts edited
  • 0 helpful flags
  • 0 votes cast
Nov
24
comment Sql Server - Best Practices for Growing Database Files
I remove the "AND instance_name = 'database your interested in" so it returns all databases. Then use a count where the log size is a above a threshold in the IF statement. If the count is higher than 1 I do a sp_send_dbmail with a select name statement from the temp table to email the names of the logs above the limit.