relational algebra - What does "in" mean and how is it different than "="?

find_the_fun

Active member
In relational algebra what does "in" mean?
For example
$$\displaystyle \sigma_{car IN car}R$$ where R is some relation.

MarkFL

Staff member
Do you mean:

$\displaystyle \sigma\in\mathbb{R}$ ?

If so, the "in" means "is an element of."

edit: I just noticed this is probably not what you are referring to! Evgeny.Makarov

Well-known member
MHB Math Scholar
In relational algebra what does "in" mean?
For example
$$\displaystyle \sigma_{car IN car}R$$ where R is some relation.
The subscript after σ is a formula. The exact syntax of such formulas depends on the context (software, textbook, etc.). As Wikipedia explains, a typical case is when atomic formulas have the form xRy where x is an attribute name, y is an attribute name or a constant, R is a relation such as <, and atomic formulas are joined by logical connectives. The formula "car IN car" is probably an atomic formula. Maybe the first "car" is an attribute name and the second "car" is an array of values. For a more precise answer one needs the context.