Skip to content

Latest commit

 

History

History
78 lines (49 loc) · 3.87 KB

File metadata and controls

78 lines (49 loc) · 3.87 KB
title Configure SQL Server Agent Mail to Use Database Mail
ms.date 08/05/2016
ms.prod sql
ms.reviewer
ms.technology
ms.topic conceptual
helpviewer_keywords
Database Mail [SQL Server], SQL Server Agent Mail
SQL Server Agent Mail
ms.assetid 4b8b61bd-4bd1-43cd-b6e5-c6ed2e101dce
author stevestein
ms.author sstein
ms.custom seo-dt-2019

Configure SQL Server Agent Mail to Use Database Mail

[!INCLUDEappliesto-ss-xxxx-xxxx-xxx-md] This topic describes how to configure [!INCLUDEssNoVersion] Agent to use Database Mail to send notification and alerts in [!INCLUDEssCurrent] by using [!INCLUDEssManStudioFull]. For information on how to enable and configure Database Mail, see Configure Database Mail. For an example using [!INCLUDEtsql], see Create a Database Mail Profile.

Before You Begin

Note

SQL Agent on Managed Instance is always configured to use Database Mail, so this content is not applicable on Managed Instance. In Managed Instance you need to have a profile that must be called AzureManagedInstance_dbmail_profile in order to bind SQL Agent with Database Mail.

Prerequisites

Security

Permissions

The user creating the profiles accounts and executing stored procedures should be a member of the sysadmin fixed server role.

Using SQL Server Management Studio

To configure SQL Server Agent to use Database Mail

  • In Object Explorer, expand a [!INCLUDEssNoVersion] instance.

  • Right-click SQL Server Agent, and then click Properties.

  • Click Alert System.

  • Select Enable Mail Profile.

  • In the Mail system list, select Database Mail.

  • In the Mail profile list, select a mail profile for Database Mail.

  • Restart SQL Server Agent .

Follow-up Tasks

The following tasks are necessary to complete the configuration of Agent to send alerts and notifications.

  • Alerts

    Alerts can be configured to notify an operator of a particular database event or operating system condition.

  • Operators

    Operators are aliases for people or groups that can receive electronic notification