private String getAsOfValue(ASTNode tabref, int asOfIndex) throws SemanticException {
    String asOfValue = null;
    if (asOfIndex != -1) {
      ASTNode expr = (ASTNode) tabref.getChild(asOfIndex).getChild(0);
      if (expr.getChildCount() > 0) {
        ExprNodeDesc desc = genExprNodeDesc(expr, new RowResolver(), false, true);
        ExprNodeConstantDesc c = (ExprNodeConstantDesc) desc;
        asOfValue = String.valueOf(c.getValue());
      } else {
        asOfValue = stripQuotes(expr.getText());
      }
    }
    return asOfValue;
  }
Goes though the tabref tree and finds the alias for the table. Once found,
it records the table name-> alias association in aliasToTabs. It also makes
an association from the alias to the table AST in parse info.

@return the alias of the table
ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java