Send email if SQL server is fauled?

I just had a situation where the SQL server was down all weekend and most of today and no one noticed. Is there a way to set up an email to be sent if the connection is faulted?

You can create an expression to query the database, using the try option and you can set your alarm on the failback value. Here, if the SQLTag Expression equals -999, there is a problem.

try(executeScalarQuery("SELECT testlong FROM test","LocalDB"),-999)

I think that’ll work! I have the expression tag set up, it’s giving me correct information, now I just need to learn how to finally set up alarming with a notification. Thank you!