Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9298539
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T22:21:01+00:00 2026-06-18T22:21:01+00:00

I ran into a very odd situation with an SSIS package I have been

  • 0

I ran into a very odd situation with an SSIS package I have been working with.

I have a foreach loop that contains a data flow task which executes for every record in a recordset object populated prior to the loop.

In the dataflow task I have an ADO.NET source, a lookup, and finally a destination script component. The script component initializes a datatable in PreExecute, adds each row from the input, and post sends the datatable as a table valued parameter to a stored procedure. The lookup task is set up to only send non-matching rows to the script component.

The odd situation is that I found when all rows on the lookup were matched the script component was still being executed with 0 rows sent to it. This resulted in an error in the stored proc as I was only ever expecting it to be called when the script component received more than 0 rows. I have corrected the issue in the stored proc itself by first doing a check that there is actually data passed in.

In other packages I have very similar situations with destination script components set up after lookups where 0 records get passed in, and have not seen this behavior occur there – the only difference is that they’re not within foreach loops.

So, I’d really like to know, for future reference, if it is the expected behavior of an an SSIS script component that it would execute with 0 rows passed in?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T22:21:02+00:00Added an answer on June 18, 2026 at 10:21 pm

    PreExecute and PostExecute methods will execute even if there are no rows to redirect from the following Lookup Transformation outputs to the Script Component configured as Destination component within Data Flow Task.

    • Lookup Match Output
    • Lookup No Match Output

    Make sure that the package that you believe is working differently than the one not working is configured in the same manner.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I ran into something odd today that maybe someone knows something about. I have
I ran into a very disturbing issue that's been puzzling me for a while
Ran into an issue today that I have not been able to resolve. I
I am working on integrating scapy with twisted, but I ran into this very
I ran into a rather odd behavior that I don't even know how to
I have ran into a very strange issue with Google Maps in Chrome 5.0.375.99:
I ran into a problem that is very similar to other SO question (
I ran into this very odd scenario. This won't hide the H1: if ($('#content
Today I ran into a very weird situation. I use several environments of my
I'm experimenting with CUDA and I ran into a very strange bug. I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.