Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to send mails from SQL via NT4 smtp

Status
Not open for further replies.

joebickley

Programmer
Aug 28, 2001
139
GB
I am trying to send a mail using a stored procedure in a database. My intention is to set this up as a job to run everyday. I can set a job and i can write the procedure but i cant send it. A book i have tells me to to set up a mail profile using outlook 98/2k and get it to send through that. The server has the smtp server stuff on as part of the NT4 option pack. I have used this to send mails via ASP scripts in the past and i want to use the same function.

A is it posible
b how?? !! :)

Joe Bickley
 
see
exec xp_sendmal.....
below are described parameters:
xp_sendmail {[@recipients =] 'recipients [;...n]'}
[,[@message =] 'message']
[,[@query =] 'query']
[,[@attachments =] attachments]
[,[@copy_recipients =] 'copy_recipients [;...n]'
[,[@blind_copy_recipients =] 'blind_copy_recipients [;...n]'
[,[@subject =] 'subject']
[,[@type =] 'type']
[,[@attach_results =] 'attach_value']
[,[@no_output =] 'output_value']
[,[@no_header =] 'header_value']
[,[@width =] width]
[,[@separator =] 'separator']
[,[@echo_error =] 'echo_value']
[,[@set_user =] 'user']
[,[@dbuse =] 'database']

Ion Filipski
1c.bmp


filipski@excite.com
 
yeah i know what the code needs to be but i need to configure the sql server with a mail account first. This is what is giving me the issues
 
In this case is not a problem of SQLServer, put your question how to configure SMTP in other forum. Ion Filipski
1c.bmp


filipski@excite.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top