String tableColumnName = tc.getName();
for (Column c : joinCols) {
String joinColumnName = c.getName();
if (tableColumnName.equals(joinColumnName)) {
// XXX join.addNaturalJoinColumn(c);
Expression tableExpr = new ExpressionColumn(session, tableSchema, last
.getTableAlias(), tableColumnName);
Expression joinExpr = new ExpressionColumn(session, joinSchema, join
.getTableAlias(), joinColumnName);
Expression equal = new Comparison(session, Operator.EQUAL, tableExpr, joinExpr);
if (on == null) {
on = equal;
} else {