I have to send mails to 100 people by using SSIS send mail task. but in SSIS mail box To address text box is having 255 characters limit where it's not allowing me to do. So could you please suggest the best way to achieve this..?
Asked
Active
Viewed 1,394 times
0
-
`Loop Container`...get the emails from a txt file and send it one by one in the loop ;) – Hackerman Feb 23 '17 at 16:40
-
I'm newbie to SSIS. could you please share some links so that i can try. – P.S. Rao Feb 23 '17 at 16:44
-
You can check this one*you can replace the script task with your mail task, but the logic should be the same: http://www.sqlservercentral.com/articles/Integration+Services+(SSIS)/71485/ – Hackerman Feb 23 '17 at 16:47
1 Answers
2
Something like this:
First task (GetUnsentEmail(s)) to select Email address (stored in a table) where 'flag' = 0 and puts those records into an object variable. The Foreach Loop Container loops through each record in that object variable and:
- puts values into variables
- executes the task "Send Mail Task" which uses those variables to send the email
- executes the sql task "Update send email table" which sets 'flag' to 1
I hope this help.

ɐlǝx
- 1,384
- 2
- 17
- 22