build context cte search

This commit is contained in:
phernandez
2025-01-19 13:57:19 -06:00
parent eaa2051a04
commit cdf38f7991
3 changed files with 17 additions and 13 deletions
+1 -1
View File
@@ -202,7 +202,7 @@ WITH RECURSIVE context_graph AS (
cg.type = 'relation' AND
e.type = 'entity' AND
e.id = CASE
WHEN cg.from_id = cg.root_id THEN cg.to_id
WHEN cg.from_id = cg.id THEN cg.to_id
ELSE cg.from_id
END
{related_date_filter}