Feature/union

DO NOT MERGE

This is a first draft of the union feature.  I still need to do some cleanup but thought this would be good for a review and to get any feedback while I finalise the commit history in particular.  I originally added to the JoinBlock but backed this out due to block ordering.