polars selector datetime for expression
Select all datetime columns. Optionally filter by time unit (ns, us, ms) and/or timezone.
Signature
> polars selector datetime {flags}
Flags
--time-unit {list<string>}: Filter by time unit(s): ns (nanoseconds), us (microseconds), ms (milliseconds).--time-zone {list<string>}: Filter by timezone(s). Use "*" to match any set timezone, or "unset" to match columns without a timezone.
Input/output types:
| input | output |
|---|---|
| any | polars_selector |
Examples
Create a selector for all datetime columns
> polars selector datetimeCreate a selector for nanosecond or microsecond datetime columns
> polars selector datetime --time-unit [ns us]Create a selector for nanosecond datetime columns with UTC timezone
> polars selector datetime --time-unit [ns] --time-zone [UTC]