|   | ![]() |
|
Configuring and Managing SQL Mail 1 2 3 4 5 6 7 Extended Stored Procedures for Mail Processing If youre building a system where youll be calling and using the SQL Mail abilities directly, youll be using the extended stored procedures for SQL mail. There are seven extended stored procedures that can be used to manage e-mail from within SQL Server and are found in the master database. The stored procedures shown in the next table are available, each is described with its respective parameters following the table.
Xp_startmail is used to start the mail services in SQL Server if they have not already been started, either by another call to this procedure or by setting the automatic start option in the SQL Mail properties. The syntax for startmail is:
The user name and password for the mailbox can be specified, but this is not necessary unless you did not specify a password for the profile that is being used when you set up the SQL Mail properties.
Xp_stopmail stops all mail processes on the server. This will shut down the connection to the mail server and subsequent calls to the mail extended stored procedures will fail until the service is restarted. Xp_stopmail is very simple, with no parameters:
|
All content on this site, except where noted, represents an original work of Michael R. Hotek and is protected by applicable copyright laws. The SQL Server FAQ is the sole work of Neil Pike. No page, portion of a page, or download may be used for commercial purposes in whole or in part without the express, written permission of the applicable author.