Skip to content

Filtering datetime index by minute in QueryBuilder #2838

@0xtflow

Description

@0xtflow

I have a DataFrame of prices with a DatetimeIndex. I’m trying to filter rows in QueryBuilder based on a specific minute value from the index.

Example:

q = adb.QueryBuilder()

q = q[q["index"].dt.minute == 10]
# AttributeError: 'ExpressionNode' object has no attribute 'dt'

q = q[q["index"].minute == 10]
# AttributeError: 'ExpressionNode' object has no attribute 'minute'

It seems that datetime accessors like .dt or .minute are not supported on ExpressionNode.

Question:
What is the correct way to filter a datetime index by time components (e.g., minute, hour, time, or exact timestamp) when using QueryBuilder? Is this functionality supported, or is there an alternative recommended approach?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions