-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Summary
The contains text search filter returns no results while equals works correctly (see screenshot). After a thorough code audit, 7 related filter issues were identified across the objectui and spec repos.
Root Cause Analysis
Bug 1 (Critical): contains filter returns empty results — Server-side double-conversion
- Frontend sends AST:
['name', 'contains', 'Evan'] - Server
parseFilterAST()converts to{ name: { $contains: 'Evan' } } - Driver receives
{ name: { $contains: 'Evan' } }but does not translate$contains→ database-native (SQL/Mongo regex) - Results are always empty.
Other issues:
notContainsoperator missing from mapping tablesisEmpty/isNotEmptyonly matches null, not empty stringsbetweenfilter renders only one input, needs min/max- Case sensitivity inconsistency (
contains) in/notInoperator expanded in frontend; drivers support natively- Same double-conversion bug for
startsWith/endsWith
Proposed Fixes
- Remove or refactor
parseFilterAST()call and let drivers process raw AST arrays - Ensure drivers (esp. Memory & SQL) correctly convert
$contains,$startsWith,$endsWith,$notContainsto native DB queries - Update frontend FilterBuilder for correct input rendering & operator mapping
Reproduction
- ListView/Contact, filter Name with Contains, value = 'Evan'
- No items found; Equals with exact value works
Affected Files
- objectui and spec repos, details in full analysis
Cross-Repo Impact
Requires coordinated changes in both objectui and spec repositories (especially data engine drivers).
Reactions are currently unavailable
Metadata
Metadata
Labels
bugSomething isn't workingSomething isn't working