Remember the problem we ran into while adding the set operations support? The list of tables for each individual sub-select consisted of a super-set of all of the tables across the entire sql and we had to filter out ones which didn't belong to this sub-select. This is exactly why. The StatementQuery.voltGetXMLSpecification is now called repeatedly on each sub-select passing the QuerySpecification for the current select as an input. The return is the corresponding voltXMLElement. The select.rangeVariables list contains the tables from this select only. The "global" rangeVariables (from the StatementQuery class which represents the entire SQL) contains the super set of all of the tables. In case of a simple select statement it actually didn't make any difference simply because both lists are identical, but this is no longer the case for the set ops statements.