• abhas (12/5/2012)


    Hi rhythm,

    I am doing below steps.

    1) Execute sql task - here I am fetching studid,studname,deptname,HodName,HodMail.

    2) I am using foreach loop

    3) In foreach loop I am using script task and sendmail task

    In script task I am fetching mailid's and writting body of message. But what happens in this case suppose there are 3 students belongs to physics dept then 3 separate mails are going to HOD.

    I want to send single mail for three students as;

    Dear Sir,

    student1,student2,student3 are absent today.Please take required action.

    Thanks

    Abaso Jadhav

    Thats what I doubted.Use send mail task outside for each loop.

    I hope you are using package level variable for stroing email ids.