Solved

xp_smtp_sendmail

Posted on 2006-06-28
7
1,279 Views
Last Modified: 2010-08-05
does anybody have a list of all parameters for xp_smtp_sendmail?  i'm looking all over the place, haven't yet found one.
0
Comment
Question by:dbaSQL
  • 5
7 Comments
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 150 total points
ID: 17000638
               http://www.sqldev.net/xp/xpsmtp.htm
0
 
LVL 17

Author Comment

by:dbaSQL
ID: 17000661
let me expand this question just a bit  --

i am trying to do this on a scheduled basis, sending the results in the body of an email:

EXEC master..xp_sendmail @recipients ='me@mydomain.com',
@query = 'exec db.dbo.procname ''parameter1'',''parameter2'',''parameter3'',''parameter4'',''parameter5''   ',
@subject='test',
@attach_results = 'false'

when running in QA, without @attach_results, xp_sendmail runs fine, the email was sent, but the body was blank.
so i'm not sure that it ran the @query

what am i missing?
0
 
LVL 17

Author Comment

by:dbaSQL
ID: 17000671
very good, aneeshattingal.  thank you for the parameters.  any thoughts on my bigger issue?
0
Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

 
LVL 17

Author Comment

by:dbaSQL
ID: 17000698
i see @query isn't in there w/all the xp_smtp_sendmail parameters
but, xp_sendmail is fine, if i can get the proc results into the body of the email
0
 
LVL 75

Assisted Solution

by:Anthony Perkins
Anthony Perkins earned 150 total points
ID: 17003035
You need to decide which protocol you want to use xp_smtp_sendmail (SMTP) or xp_sendmail (MAPI).

And no, you cannot use xp_smtp_sendmail to send a query. It does not work that way.
0
 
LVL 17

Author Comment

by:dbaSQL
ID: 17003688
i guess I just wasn't thinking about it the right way this morning when i submitted this inquiry.  
i am using xp_smtp_sendmail in a bit of a customized by bill wunder.  (see:  http://www.sswug.org/see/15091)

i didn't know, though, that @query wasn't a parameter for xp_smtp_sendmail.  i thought surely it was available to me.
0
 
LVL 17

Author Comment

by:dbaSQL
ID: 17003715
thank you both.  i am splitting as my question was split and then answered by both of you
again, thank you both very much
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
I have a large data set and a SSIS package. How can I load this file in multi threading?
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question