Solved

xp_sendmail specify sender:

Posted on 2002-06-20
2
460 Views
Last Modified: 2007-12-19
I have a question regarding xp_sendmail in sql server 2000.

SQL Mail is using an Outlook profile called 'SQLMail',
which I have configured with a mailbox called 'SQLMail'.
The sa_sql-account has permissions to the mailbox.
Everything works fine.

Here comes the problem.
All the mails being sent comes from the same sender (SQLMail).
I would like to specify the sender.

Ex I have a table with message, subject, attachments, recipients and sender.
Sender is a valid exchange mailbox. sa_sql has permissions to all mailboxes on the exchange server.

In Outlook I can specify the sender in a From field. I want to do the same from sql server.
0
Comment
Question by:ola
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 6

Accepted Solution

by:
curtis591 earned 200 total points
ID: 7096540
I know of no way to do it with xp_sendmail but you might be able to use OLE Automation with Outlook from inside a SQL stored procedure to send your message.  
0
 
LVL 3

Author Comment

by:ola
ID: 7096657
I found an article on this.
http://support.microsoft.com/default.aspx?scid=kb;en-us;Q312839

With this solution mails is sent through smtp.

I think I need a mapi solution. The mails sent should
be stored in 'Sent Items' in the senders Mailbox.

0

Featured Post

Back Up Your Microsoft Windows Server®

Back up all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

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

Suggested Solutions

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
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.

756 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