private static boolean findSourceColumn(
      LineageCtx lctx, Predicate cond, String tabAlias, String alias) {
    for (Map.Entry<String, TableScanOperator> topOpMap: lctx.getParseCtx().getTopOps().entrySet()) {
      TableScanOperator tableScanOp = topOpMap.getValue();
      Table tbl = tableScanOp.getConf().getTableMetadata();
      if (tbl.getTableName().equals(tabAlias)
          || tabAlias.equals(tableScanOp.getConf().getAlias())) {
        for (FieldSchema column: tbl.getCols()) {
          if (column.getName().equals(alias)) {
            TableAliasInfo table = new TableAliasInfo();
            table.setTable(tbl.getTTable());
            table.setAlias(tabAlias);
            BaseColumnInfo colInfo = new BaseColumnInfo();
            colInfo.setColumn(column);
            colInfo.setTabAlias(table);
            cond.getBaseCols().add(colInfo);
            return true;
          }
        }

      }
    }
    return false;
  }
Processor for constants and null expressions. For such expressions the
processor simply returns a null dependency vector.
ql/src/java/org/apache/hadoop/hive/ql/optimizer/lineage/ExprProcFactory.java