diff --git a/basen/src/left_outer_join.hf b/basen/src/left_outer_join.hf new file mode 100644 index 000000000..5c4e007b7 --- /dev/null +++ b/basen/src/left_outer_join.hf @@ -0,0 +1,21 @@ +lhs = mod[0] + -> tee(); +rhs = mod[1] + -> tee(); + +lhs -> [0]joined; +rhs -> [1]joined; + +joined = join::<'tick,'static>() + -> map(|(k, (lhs, rhs))| (k, (lhs, Some(rhs)))) + -> combined; + +lhs -> [pos]missed; +rhs -> map(|(k, _v)| k) -> [neg]missed; + +missed = anti_join::<'tick,'static>() + -> map(|(k, v)| (k, (v, None))) + -> combined; + +combined = union() + -> mod;