SSIS Precedence Contraint isn't processing

Posted on 2013-09-20
Medium Priority
Last Modified: 2016-02-11
I have an SQL task that selects the count of records, and the result is returned to a variable, ServiceExists.
I have set 2 precedence contraints to go to 2 different tasks, based on the value of the variable, one is @[User::ServiceExists] > 0, and the other is @[User::ServiceExists] == 0.
The flow works when the count is > 0, but when it is 0, it stops.

can anyone tell me why?
Question by:Tony Oswald
  • 2
LVL 66

Accepted Solution

Jim Horn earned 2000 total points
ID: 39509627
<wild guesses>

Make sure the evaluation operation says 'Expression and Constraint', and not just 'Constraint', and that 'Logical OR' is selected.
Also make sure the variable is numeric, as the number 0 is not the same as the string '0'.

Author Closing Comment

by:Tony Oswald
ID: 39509638
changed from AND to OR and it worked!!
LVL 66

Expert Comment

by:Jim Horn
ID: 39509653
Gotta love how intuitive SSIS expressions are.

Thanks for the grade.  Good luck with your project.  -Jim

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
In this article, we will show how to detach and attach a database and then show how to repair a corrupt database and attach it, If it has some errors. We will show how to detach and attach using SSMS or using T-SQL sentences.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

607 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