Error to variable in SSIS

Posted on 2012-08-16
Last Modified: 2012-08-21
I have an SSIS package that runs a data flow task. I am trying to send out and email and write to a progress log if the task succeeds or fails.

If the data flow task fails how can I insert the failure reason into the a variable for later use in an email / sql statement?

Question by:ubya308
    LVL 39

    Accepted Solution

    Please see SSIS logging and as far as emailing the error I believe you can use BEGIN/TRY/CATCH to see if there's some error and send an email if there is from the t-sql SSIS task. otherwise you can log it into a SQL table and put a trigger on that table to send an email if some error encountered - like an insert trigger where the message contains the error.
    LVL 14

    Assisted Solution

    by:nishant joshi
    first create new global variable of package which whould be blank and create one local variable in error handlert.if error raise then on expression concate the variable strings...

    Featured Post

    Why You Should Analyze Threat Actor TTPs

    After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

    Join & Write a Comment

    Introduction SQL Server Integration Services can read XML files, that’s known by every BI developer.  (If you didn’t, don’t worry, I’m aiming this article at newcomers as well.) But how far can you go?  When does the XML Source component become …
    Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
    Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
    Viewers will learn how the fundamental information of how to create a table.

    730 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now