SSIS 优先约束 - 带 AND 的表达式

SSIS precedence constraint - expression with AND

我正在使用 Visual Studio 2019 和 SQL 服务器 SSIS。

在优先约束中,如何在表达式中使用 AND

例如,如果我有:

@myVariable1 == 0 AND @myVariable2 == 0

我收到消息

Expression cannot be evaluated

这就是我想要实现的目标:

我知道双管道运算符是合乎逻辑的 ORAND 有类似的东西吗?

你需要像这样使用&&

@myVariable1 == 0 && @myVariable2 == 0

这是 SSIS 表达式运算符的完整列表:

Operator Description
Cast Converts an expression from one data type to a different data type.
() (Parentheses) Identifies the evaluation order of expressions.
+ (Add) (SSIS) Adds two numeric expressions.
+ (Concatenate) Concatenates two expressions.
- (Subtract) Subtracts the second numeric expression from the first one.
- (Negate) Negates a numeric expression.
* (Multiply) Multiplies two numeric expressions.
/ (Divide) Divides the first numeric expression by the second one.
% (Modulo) Provides the integer remainder after dividing the first numeric expression by the second one.
|| (Logical OR) Performs a logical OR operation.
&& (Logical AND) Performs a logical AND operation.
! (Logical NOT) Negates a Boolean operand.
| (Bitwise Inclusive OR) Performs a bitwise OR operation of two integer values.
^ (Bitwise Exclusive OR) Performs a bitwise exclusive OR operation of two integer values.
& (Bitwise AND) Performs a bitwise AND operation of two integer values.
~ (Bitwise NOT) Performs a bitwise negation of an integer.
== (Equal) Performs a comparison to determine if two expressions are equal.
!= (Unequal) Performs a comparison to determine if two expressions are not equal.
> (Greater Than) Performs a comparison to determine if the first expression is greater than the second one.
< (Less Than) Performs a comparison to determine if the first expression is less than the second one.
>= (Greater Than or Equal To) Performs a comparison to determine if the first expression is greater than or equal to the second one.
<= (Less Than or Equal To) Performs a comparison to determine if the first expression is less than or equal to the second one.
? : (Conditional) Returns one of two expressions based on the evaluation of a Boolean expression.