MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / union

Method union

src/sql/src/plan/hir.rs:1908–1926  ·  view source on GitHub ↗
(self, other: Self)

Source from the content-addressed store, hash-verified

1906 }
1907
1908 pub fn union(self, other: Self) -> Self {
1909 let mut terms = Vec::new();
1910 if let HirRelationExpr::Union { base, inputs } = self {
1911 terms.push(*base);
1912 terms.extend(inputs);
1913 } else {
1914 terms.push(self);
1915 }
1916 if let HirRelationExpr::Union { base, inputs } = other {
1917 terms.push(*base);
1918 terms.extend(inputs);
1919 } else {
1920 terms.push(other);
1921 }
1922 HirRelationExpr::Union {
1923 base: Box::new(terms.remove(0)),
1924 inputs: terms,
1925 }
1926 }
1927
1928 pub fn exists(self) -> HirScalarExpr {
1929 HirScalarExpr::Exists(Box::new(self), NameMetadata::default())

Callers 10

check_object_privilegesFunction · 0.45
all_object_privilegesFunction · 0.45
applied_toMethod · 0.45
apply_scalar_subqueryFunction · 0.45
attempt_outer_equijoinFunction · 0.45
plan_set_exprFunction · 0.45
json_specMethod · 0.45
col_jsonMethod · 0.45
col_valuesMethod · 0.45

Calls 3

pushMethod · 0.45
extendMethod · 0.45
removeMethod · 0.45

Tested by

no test coverage detected