sqlite: Add test for search with list filters (#4747)

This commit is contained in:
William FH
2025-05-18 23:50:27 -07:00
committed by GitHub
parent 6b28319796
commit 95f92069a7
7 changed files with 127 additions and 6 deletions
@@ -410,11 +410,12 @@ class BaseSqliteStore:
"json_extract(value, '$." + key + "') = " + str(value)
)
else:
# For complex objects, use param binding with JSON serialization
# Complex objects (list, dict, …) compare JSON text
filter_conditions.append(
"json_extract(value, '$." + key + "') = ?"
)
filter_params.append(orjson.dumps(value))
# orjson.dumps returns bytes → decode to str so SQLite sees TEXT
filter_params.append(orjson.dumps(value).decode())
# Vector search branch
if op.query and self.index_config: