zcollection.collection.Collection.drop_partitions#
- Collection.drop_partitions(*, filters=None, timedelta=None)[source]#
Drop the selected partitions.
- Parameters:
filters (str | Callable[[Dict[str, int]], bool] | None) – The predicate used to filter the partitions to drop. To get more information on the predicate, see the documentation of the
partitions()
method.timedelta (timedelta | None) – Select the partitions created before the specified time delta relative to the current time.
- Returns:
A list of the dropped partitions.
- Return type:
Example
>>> collection.drop_partitions(filters="year == 2019") >>> collection.drop_partitions( ... timedelta=datetime.timedelta(days=30))