Skip to content

sparse bloom index contains() function doesn't properly handle array of recordsΒ #10075

Closed

Description

@akuzm
# select _timescaledb_functions.bloom1_contains_any('\x0102030405060708'::_timescaledb_internal.bloom1, array[row(1, 'x')]);
ERROR:  42704: type with OID 0 does not exist

I couldn't quickly fix it, looks like some artifact of special handling of record types that we need for composite bloom filters.

Activity

  1. akuzm commented on Jun 17, 2026

    @akuzm
    MemberAuthor

    This can be a relatively serious problem because it reads memory using a wrong type, can potentially segfault. cc @dbeck

  2. akuzm commented on Jun 17, 2026

    @akuzm
    MemberAuthor
    # select array[row(1, 'x'), row('y')];
         array     
    ───────────────
     {"(1,x)",(y)}
    

    Not sure if we can make this can work at all, elements can have different type.

  3. self-assigned this
    on Jul 14, 2026
  4. dbeck commented on Jul 14, 2026

    @dbeck
    Member

    I'll check if the records in the array are the expected shape for the bloom filter, and return 'true' for the contains function, bypassing the bloom filtering.

  5. added a commit that references this issue on Nov 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions