Welcome to our community

Be a part of something great, join today!

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

find_the_fun

Active member
Feb 1, 2012
166
In relational algebra what does "in" mean?
For example
\(\displaystyle \sigma_{car IN car}R\) where R is some relation.
 

MarkFL

Administrator
Staff member
Feb 24, 2012
13,775
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! (Doh)
 

find_the_fun

Active member
Feb 1, 2012
166

Evgeny.Makarov

Well-known member
MHB Math Scholar
Jan 30, 2012
2,492
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.