@Override
  public List<WriteEventInfo> getAllWriteEventInfo(long txnId, String dbName, String tableName) throws MetaException {
    List<WriteEventInfo> writeEventInfoList = null;
    boolean commited = false;
    Query query = null;
    try {
      openTransaction();
      List<String> parameterVals = new ArrayList<>();
      StringBuilder filterBuilder = new StringBuilder(" txnId == " + Long.toString(txnId));
      if (dbName != null && !"*".equals(dbName)) { // * means get all database, so no need to add filter
        appendSimpleCondition(filterBuilder, "database", new String[]{dbName}, parameterVals);
      }
      if (tableName != null && !"*".equals(tableName)) {
        appendSimpleCondition(filterBuilder, "table", new String[]{tableName}, parameterVals);
      }
      query = pm.newQuery(MTxnWriteNotificationLog.class, filterBuilder.toString());
      query.setOrdering("database,table ascending");
      List<MTxnWriteNotificationLog> mplans = (List<MTxnWriteNotificationLog>)query.executeWithArray(
              parameterVals.toArray(new String[0]));
      pm.retrieveAll(mplans);
      commited = commitTransaction();
      if (mplans != null && mplans.size() > 0) {
        writeEventInfoList = Lists.newArrayList();
        for (MTxnWriteNotificationLog mplan : mplans) {
          WriteEventInfo writeEventInfo = new WriteEventInfo(mplan.getWriteId(), mplan.getDatabase(),
                  mplan.getTable(), mplan.getFiles());
          writeEventInfo.setPartition(mplan.getPartition());
          writeEventInfo.setPartitionObj(mplan.getPartObject());
          writeEventInfo.setTableObj(mplan.getTableObject());
          writeEventInfoList.add(writeEventInfo);
        }
      }
    } finally {
      rollbackAndCleanup(commited, query);
    }
    return writeEventInfoList;
  }
Get partition's column stats

@return Map of column name and its stats
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/ObjectStore.java