Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

xp_sendmail

Status
Not open for further replies.

bertrandkis

Programmer
Jul 26, 2002
101
ZA
Hello folks, I am sending a email from sql server that consists of results of a query and that's working perfect.
When I open the text file generated by xp_sendmail in notepad it's OK, but when I open it in MS Word or WordPad, I see garbage characters in form of squares added to the content. Is there something I can do to correct this?
Thanks in anticipation for your help.
 
Unicode data... :(

------
[small]select stuff(stuff(replicate('<P> <B> ', 14), 109, 0, '<.'), 112, 0, '/')[/small]
[banghead]
 
Thanks for the tip. However the Stuff() function will not work as the code is dymanic and I am using a Select * to generate the query because the column names and number of columns change. So what I need now is to change the Database collation before I generete the mail and then set it back to it's initial value after the email is generated.
I need help with the script to do this. The BOL does not seem to give me what I need.
Thanks again
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top