problem send email with-xp_SMTPSendMail-result of a query

  • i have a problem with xp_SMTPSendMail  from (http://www.thorpesoftware.com/)

    on windows 2003 R2 + sql server 2005

    i have tow servers

    1) windows 2000 + sql server 2000

    2)(the new) windows 2003 R2 + sql server 2005

    i have jobs that run on the (sql server 2000) that send an Email with  result of a query including a style sheet

    whan i copy the lob to the (windows 2003 R2 + sql server 2005)

    i can not send the  result of a query including a style sheet by email

    only simple email (Send an informational mail)

    someone can halp ??

    tnx

  • EXEC master.dbo.xp_sendmail

    @recipients = N'danw@Adventure-Works.com',

    @query = N'SELECT * FROM INFORMATION_SCHEMA.TABLES',

    @subject = N'SQL Server Report',

    @message = N'The contents of INFORMATION_SCHEMA.TABLES:',

    @attach_results = 'TRUE',

    @width = 250 ;

  • In my opinion, you should be migrating away from xp_smtpsendmail in your SQL Server 2005 install as Database Mail using SMTP and also is now asynchronous through it's use of Service Broker.

    It can also help you reduce the surface area of your SQL Server by allowing you to disable use of extended procedures (if you aren't using them elsewhere).

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply