1

I have a stored procedure the runs sp_makewebtask to create a .HTM file. Thie file consists of an image and the output of a query along with some addtional verbage. What I would like to do is to send out that .HTM file using sp_send_dbmail. I know I can bypass the sp_makewebtask step and dynamically create the .HTM file but I am hoping to avoid this. Any ideas? Thanks

EXEC msdb.dbo.sp_send_dbmail @recipients='John.Testing@companyX.COM',
@subject = 'My Mail Test',
@body = @Var1, --Basically I want to know how I can replace the @Var1 with the dynamically created .HTM file
@body_format = 'HTML'

user142253
  • 494
  • 1
  • 6
  • 16

0 Answers0