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 7582539
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T18:27:32+00:00 2026-05-30T18:27:32+00:00

I am getting to know SSIS, I apologize if the question is too simple.

  • 0

I am getting to know SSIS, I apologize if the question is too simple.

I got a set of tasks inside a foreach-loop-container.
The first task needs only to get executed on condition that a certain user variable is not null or empty.
Otherwise, the flow should skip the first task and continue to the second one.

How would I go about realizing this (in detail) ?

  • 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-05-30T18:27:33+00:00Added an answer on May 30, 2026 at 6:27 pm

    Issue 1: There are two ways to interpret your logic: “…a certain user variable is not null or empty”:

    1. The (Variable is Not Null) OR the (Variable is Empty).
    2. The (Variable is Not Null) OR the (Variable is Not Empty).

      It’s all about the object(s?) of the word “not”. The differences are subtle but will impact when the first task in the Foreach loop executes. For demonstration purposes, I am assuming you intend #1.

      Issue 2: The first task can no longer be first. In order to accomplish what you desire using SSIS inside the BIDS environment, you need to place another task ahead of the task formerly known as “the first task”. This is so you can set a Precedence Constraint on the former first task from the new first task.
      It is possible to accomplish what you desire by designing your SSIS dynamically from managed code, but I don’t think this issue warrants the overhead associated with that design choice.
      I like using an empty Sequence Container as an “Anchor” task – a task that exists solely to serve as the starting endpoint of a Precedence Constraint. I heavily document them as such. I don’t want anyone deleting the “unnecessary empty container” and roaming the halls for days shaking their heads and repeating “Andy, Andy, Andy…” but I digress.

      In the example below, I have two precedence constraints leaving the empty Sequence Container. One goes to the task that may be skipped and the other to the task following the task that can sometimes be skipped. A third precedence constraint is required between the task that can sometimes be skipped and the task following. It is important to note this third precedence constraint must be edited and the Multiple Constraints option set to OR. This allows the task following to execute when either of the mutually exclusive previous paths are taken. By default, this is set to AND and will require both paths to execute. By definition, that will not – cannot – happen with mutually exclusive paths.

      I test the value of an SSIS String variable named @MyVar to see if it’s Null or Empty. I used the Expression Only Evaluation Option for the constraints leaving the empty Sequence Container. The expressions vary but establish the mutual exclusivity of the expression. My Foreach Loop Container looks like this:

    SSIS diagram

    I hope this helps.

    :{>

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

Sidebar

Related Questions

Hi Anyone know of a simple system of getting xml formatted inside an editor.
This is my first post, so I'm just getting to know how the community
I'm using Collections.synchronizedCollection in Java to protect a Set that I know is getting
I'm just getting to know AppleScriptObj-C and trying to create a simple application that
I am getting to know boost::variant. I think this example should work. #include <boost/fusion/sequence.hpp>
I'm currently getting to know Java and OSGi, so I've read a few books.
I'm new to OpenGL. I have written a programm before getting to know OpenGL
I know there has to be a way: I need help getting any hot
I know there are many tutorials out there for getting started in C. However
I know it can be done but am having issues getting it to work.

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.