May 17, 2010 at 11:28 pm
Hi all
I need to create a job on production environment, which does the following:
1. Fetches data from a number of tables, the query is quite big.
2. Creates an excel sheet, in required format.
3. Mails the same excel sheet to a particular user.
Can anyone provide a lead to this? Is it possible to send the same attachment using mail services of SQL server? Which command should be best suited for the excel file creation, to create the excel file of particular name at same location everytime, with same name replacing the previous file.
Thank you.
May 17, 2010 at 11:31 pm
Create an SSIS package and schedule that
May 17, 2010 at 11:40 pm
The DB is in SQL server 2000 and need to do through job only, cant do through SSIS/DTS.
May 17, 2010 at 11:56 pm
Can u please let me know y cant u use DTS?
May 17, 2010 at 11:58 pm
I would recommend you to use BCP feature available in SQL Server 2000 to copy the results of the SQL query to an excel file, then use xp_sendmail mail feature to send the generated excel file to the desired recipients.
May 18, 2010 at 12:00 am
Even if ur database is in 2000 u can create SSIS package..
Or
U can craete a stored procedure for the same
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply