How to display a pause and warning message in SSIS

  • I wanted to create a pause with a warning message at the beginning of certain packages due to the potential impact on the database. How would I do this with SSIS?

  • tripower (8/13/2010)


    I wanted to create a pause with a warning message at the beginning of certain packages due to the potential impact on the database. How would I do this with SSIS?

    You can do that using Msgbox inside activex script task.

    [font="Arial"]BASKAR BV
    http://geekswithblogs.net/baskibv/Default.aspx
    In life, as in football, you won’t go far unless you know where the goalposts are.[/font]

  • A warning message? I don't think SSIS is designed to do that: it runs as a service and doesn't depend on anybody being logged on interactively. If you still wanted to do it, I suppose you can write a VB script (other languages are available) that will pop up a message and wait for aknowledgement from a user. Your only difficulty now is knowing whether there's a user logged on to see it.

    John

  • OK, I did that with a VB scrip message box that has an OK and Cancel button but how to I cancel execution of the package if the user clicks cancel.

  • tripower (8/13/2010)


    OK, I did that with a VB scrip message box that has an OK and Cancel button but how to I cancel execution of the package if the user clicks cancel.

    You are mostly using SSIS like a front-end application though SSIS is designed for ETL and it should be used without any user intervention... How you are planning to execute this in production? Because once you schedule this job these warning message only appear in the system where you scheduled it.

    Instead if the graph is only for one user and who is going to run this from his machine on demand then it should be fine.

    Anyways, u can achieve that using something like below code...

    Dim x As MsgBoxResult

    x = MsgBox("test message", MsgBoxStyle.YesNo)

    If x = MsgBoxResult.Yes Then

    Dts.TaskResult = Dts.Results.Success

    Else

    Dts.TaskResult = Dts.Results.Failure

    End If

    [font="Arial"]BASKAR BV
    http://geekswithblogs.net/baskibv/Default.aspx
    In life, as in football, you won’t go far unless you know where the goalposts are.[/font]

  • Baskar B.V (8/13/2010)


    tripower (8/13/2010)


    I wanted to create a pause with a warning message at the beginning of certain packages due to the potential impact on the database. How would I do this with SSIS?

    You can do that using Msgbox inside activex script task.

    Hello Baskar,

    I'm sure that we all BI-developers are of the believe that ETL processess should not include much of UserInteraction as they are a set of automated process.

    In this case, Well my approach would be to create Event Handlers as and when necessary so that the package continues to run and log the necessary details as and when the need arises rather than using a messageBox.

    I am keen to know if i'm mistaken.:-):-)

    Raunak J

  • Hi,

    I wanted to know, if we can obtain/receive (through variable) the warning message, and log in a custom table.

    I have created a sql task in onwarning handler, but i dont know, how to obtain the warning.

    Could you help me out.

    Regards,

    Vijay

  • nakvijay (5/30/2011)


    Hi,

    I wanted to know, if we can obtain/receive (through variable) the warning message, and log in a custom table.

    I have created a sql task in onwarning handler, but i dont know, how to obtain the warning.

    Could you help me out.

    Regards,

    Vijay

    How is this related to the original topic? Please start-up a new thread.

    Need an answer? No, you need a question
    My blog at https://sqlkover.com.
    MCSE Business Intelligence - Microsoft Data Platform MVP

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply