Solved

Appending attachment using sp_send_dbmail

Posted on 2008-06-25
1
853 Views
Last Modified: 2008-06-25
The email sends, but without the attachment.  Is there a problem with the code or does something need to be manipulated within the SQL Server settings?

msdb.dbo.sp_send_dbmail  @profile_name =  'Test' ,
@recipients = 'bill123453@yahoo.com',
@subject =  'Test' ,
@body =  'Test' ,
@query_attachment_filename =  'C:\Test.txt'
0
Comment
Question by:srejja
1 Comment
 
LVL 8

Accepted Solution

by:
sbagireddi earned 500 total points
ID: 21868578
Database Mail uses the Microsoft Windows security context of the current
user to control access to files. Therefore, users who are authenticated with
SQL Server Authentication cannot attach files using @file_attachments.

Are you authenticated as a SQL user.
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

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

Suggested Solutions

Read about achieving the basic levels of HRIS security in the workplace.
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…

777 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