Skip to content

Conversation

@dimitrovmaksim
Copy link
Member

@dimitrovmaksim dimitrovmaksim commented Feb 10, 2026

Resolves #6239

Fixes incorrect generation and execution of case-insensitive list filters (_contains_nocase, _not_contains_nocase) for non-String types, resulting in SQL error operator does not exist: bytea ~~* bytea

  1. Schema Generation (graph/src/schema/api.rs)
  • Only emit _nocase list filter variants when the element type supports case-insensitive operations
  • Updated test validates that pools: [Pool!]! (Bytes ID) no longer generates nocase filters
  1. Query Execution (store/postgres/src/relational_queries.rs)
  • Added validation to reject ILike/NotILike operations on non-String columns
  • Returns clear UnsupportedFilter error instead of opaque SQL failure

Note: I don't think there's a way to do this without returning any kind of error, unless we silently downgrade nocase to casesensitive for non-String types, or cast other types to ::text in the where clause.

Signed-off-by: Maksim Dimitrov <dimitrov.maksim@gmail.com>
Signed-off-by: Maksim Dimitrov <dimitrov.maksim@gmail.com>
@dimitrovmaksim dimitrovmaksim force-pushed the bugfix/do-not-build-nocase-filters-for-non-string-types branch from 5aa7d5c to 0faa110 Compare February 10, 2026 21:39
@dimitrovmaksim dimitrovmaksim self-assigned this Feb 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Error when using contains_nocase

1 participant