public String getTableAliasContainingColumn(String columnName) {
    String result = null;

    for (Map.Entry<String, Map<String, ColumnInfo>> entry: this.rslvMap.entrySet()) {
      if (entry.getValue().containsKey(columnName)) {
        result = entry.getKey();
      }
    }

    return result;
  }
Get alias of the last table containing  column columnName

@param columnName column
@return table alias or null
ql/src/java/org/apache/hadoop/hive/ql/parse/RowResolver.java