private void createOrAlterStorageHiveTable(Table parent, String storageTableNamePrefix, StorageTableDesc crtTblDesc) throws LensException { try { Table tbl = Storage.getStorageTable(storageTableNamePrefix, getClient(), parent, crtTblDesc); if (tableExists(tbl.getTableName())) { // alter table alterHiveTable(tbl.getTableName(), tbl); } else { getClient().createTable(tbl); // do get to update cache getTable(tbl.getTableName()); } } catch (HiveException e) { throw new LensException("Exception creating table", e); } }
private void createOrAlterStorageHiveTable(Table parent, String storageTableNamePrefix, StorageTableDesc crtTblDesc) throws LensException { try { Table tbl = Storage.getStorageTable(storageTableNamePrefix, getClient(), parent, crtTblDesc); if (tableExists(tbl.getTableName())) { // alter table alterHiveTable(tbl.getTableName(), tbl); } else { getClient().createTable(tbl); // do get to update cache getTable(tbl.getTableName()); } } catch (HiveException e) { throw new LensException("Exception creating table", e); } }