Relation:union

Uses the two relations top of the stack and creates a new relation that containts the tuples of both relations. The tuples must have the same columns.

Description

union

Parameters

None.

Examples

Using the sample relation films.csv

read "films.csv"
dup
select director == "Godard"
swap
select director == "Truffaut"
union

film director year
A bout de souffle Godard 1960
Pierrot le fou Godard 1965
Week-End Godard 1967
Tirez sur le pianiste Truffaut 1960
Jules et Jim Truffaut 1962

Comments

Tuples in both relatins must have the same columns, but not necessarily in the same order, because the order of the columns does not matter.

See also

difference intersection