• I can't work out what your problem is - there are no UNIONs in your code.

    John