The join() function takes two or more non-contiguous ranges and joins them into a single dataset.
dataset join(rA, rB, ...)
Returns a single dataset, in general used for further calculations (math, statistical, etc.)
The following joins several ranges into a single dataset, then calculates a total value.
total(join(col(a):col(a),col(b):col(b))); // joins defined ranges and calculates total
=total(join(A1:A32,B1:B32)) //same as above, but use this syntax for cell or column formula only