How to check the SSIS package job results after it has completed its execution?

前端 未结 4 1557
谎友^
谎友^ 2020-12-09 04:40

I have an SSIS package which imports the data into the SQL Server 2008 database. I have set up the schedule job in the SQL Server Agent to run that package. When I check th

4条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-09 05:24

    If you are just interested in knowing the columns being processed and not interested with the info for further use, one possible option is making use of the SSIS logging feature. Here is how it works for data flow tasks.

    1. Click on the SSIS package.
    2. On the menus, select SSIS --> Logging...
    3. On the Configure SSIS Logs: dialog, select the provider type and click Add. I have chosen SQL Server for this example. Check the Name checkbox and provide the data source under Configuration column. Here SQLServer is the name of the connection manager. SSIS will create a table named dbo.sysssislog and stored procedure dbo.sp_ssis_addlogentry in the database that you selected. Refer screenshot #1 below.
    4. If you need the rows processed, select the checkbox OnInformation. Here in the example, the package executed successfully so the log records were found under OnInformation. You may need to fine tune this event selection according to your requirements. Refer screenshot #2 below.
    5. Here is a sample package execution within data flow task. Refer screenshot #3 below.
    6. Here is a sample output of the log table dbo.sysssislog. I have only displayed the columns id and message. There are many other columns in the table. In the query, I am filtering the output only for the package named 'Package1' and the event 'OnInformation'. You can notice that records with ids 7, 14 and 15 contain the rows processed. Refer screenshot #4 below.

    Hope that helps.

    Screenshot #1:

    Logging

    Screenshot #2:

    Events

    Screenshot #3:

    Execution

    Screenshot #4:

    Data

提交回复
热议问题