Good Night. I'm exporting an excel file to my email from SQL SERVER 2012
Why, if it generates me and my email arrives to me the excel the bad thing is that it comes out in a single cell as the image that I attached Would there be a way to format the excel?
The code that generates and sends to the mail is this:
EXEC msdb.dbo.sp_send_dbmail
@profile_name = 'IncidenciasQa',
@recipients = '[email protected]',
@subject = 'Test',
@query = N'exec DBRevisoria.dbo.[Sp_RevCatalogo] 13,2',
@attach_query_result_as_file = 1,
@query_result_width = 150,
@query_result_header= 1,
@query_attachment_filename = 'test.xls',
@importance = 'High',
@query_result_no_padding = 1,
@query_result_separator = ' '