Page MenuHomePhabricator

Group query results under the "ANCESTOR" operator unconditionally
ClosedPublic

Authored by epriestley on May 24 2017, 6:51 PM.
Tags
None
Referenced Files
F18094678: D18012.diff
Thu, Aug 7, 10:17 PM
F18001435: D18012.id43323.diff
Sat, Aug 2, 8:46 AM
F17945060: D18012.diff
Thu, Jul 31, 11:10 AM
F17784684: D18012.id.diff
Jul 24 2025, 1:00 PM
F17759135: D18012.id43330.diff
Jul 22 2025, 6:06 PM
F17758785: D18012.diff
Jul 22 2025, 5:41 PM
F17727225: D18012.id43323.diff
Jul 19 2025, 1:36 AM
F17677142: D18012.diff
Jul 13 2025, 11:10 AM
Subscribers
None

Details

Summary

Fixes T12753. See that task for reproduction instructions.

We add a GROUP BY clause to queries with an "ANCESTOR" edge constraint only if the constaint has more than one PHID, but this is incorrect: the same row can be found twice by an ANCESTOR query if task T is tagged with both "B" and "C", children of "A", and the user queries for "tasks in A".

Instead, always add GROUP BY for ANCESTOR queries.

Test Plan
  • Followed test plan in T12753.
  • Saw proper paging controls after change.
  • Saw GROUP BY in DarkConsole.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable