AndExpr

Check if both of two expressions are logically true.

Top of page

Related Syntax Constructs

The following construct(s) refer to this construct:


Syntax

AndExpr

graphics/AndExpr.png

Expr Expr

Description

An AndExpr is a logical expression that is evaluated by determining the effective boolean value (ebv) of each of its operands. The value of the AndExpr is then determined as follows:

and expression ebv(op2) = true ebv(op2) = false error in ebv(op2)
ebv(op1) = true true false error
ebv(op1) = false false false false or error
error in ebv(op1) error false or error error

Example

  • Select all patients born in 1950 and living in Bradford:

    for $a in input()/patient
    where $a/born = 1950 and $a//city = "Bradford"
    return $a