Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 sql xp_sendmail

Author  Topic 

akpaga
Constraint Violating Yak Guru

331 Posts

Posted - 2008-05-28 : 10:39:16
hi

i have a text file which i need to send to another person by email as an attachment.
How can i send this using xp_sendmail.

thanks

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-05-28 : 10:53:39
You can send a file attachment using xp_sendmail by passing file name as value of @attachment parameter

http://doc.ddart.net/mssql/sql70/xp_aa-sz_11.htm
Go to Top of Page

akpaga
Constraint Violating Yak Guru

331 Posts

Posted - 2008-05-28 : 11:01:21
thanks
can u provide a an example please
Go to Top of Page

akpaga
Constraint Violating Yak Guru

331 Posts

Posted - 2008-05-28 : 11:53:30
i tried the example but its asking to provide the qury parameter

but i want to send an already existing text file and not the query results in the form of text file.
hope i am clear

Thanks in advance
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-05-28 : 12:48:49
quote:
Originally posted by akpaga

i tried the example but its asking to provide the qury parameter

but i want to send an already existing text file and not the query results in the form of text file.
hope i am clear

Thanks in advance


can you post query used?
Go to Top of Page

akpaga
Constraint Violating Yak Guru

331 Posts

Posted - 2008-05-28 : 15:12:29
i got it thanks to you
Go to Top of Page

tosscrosby
Aged Yak Warrior

676 Posts

Posted - 2008-05-28 : 15:33:54
Would you be willing to post the solution to share with others??

Terry
Go to Top of Page
   

- Advertisement -