Skip to content

Commit

Permalink
address the comments
Browse files Browse the repository at this point in the history
  • Loading branch information
zjuwangg committed Jun 24, 2019
1 parent 2fa1d28 commit 6108a3c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Expand Up @@ -1125,12 +1125,13 @@ public void alterPartitionColumnStatistics(ObjectPath tablePath, CatalogPartitio
}

@Override
public CatalogTableStatistics getTableStatistics(ObjectPath tablePath) throws TableNotExistException, CatalogException {
public CatalogTableStatistics getTableStatistics(ObjectPath tablePath) throws TableNotExistException,
CatalogException, TableNotPartitionedException {
Table hiveTable = getHiveTable(tablePath);
if (!isTablePartitioned(hiveTable)) {
return createCatalogTableStatistics(hiveTable.getParameters());
} else {
return CatalogTableStatistics.UNKNOWN;
throw new TableNotPartitionedException(getName(), tablePath);
}
}

Expand Down
Expand Up @@ -424,8 +424,9 @@ void dropFunction(ObjectPath functionPath, boolean ignoreIfNotExists)
*
* @throws TableNotExistException if the table does not exist in the catalog
* @throws CatalogException in case of any runtime exception
* @throws TableNotPartitionedException if the table is not partitioned
*/
CatalogTableStatistics getTableStatistics(ObjectPath tablePath) throws TableNotExistException, CatalogException;
CatalogTableStatistics getTableStatistics(ObjectPath tablePath) throws TableNotExistException, CatalogException, TableNotPartitionedException;

/**
* Get the column statistics of a table.
Expand Down

0 comments on commit 6108a3c

Please sign in to comment.