- πΊπΈUnited States bwong
This patch was initially submitted to address an integration issue with modules like Views Raw SQL β .
As it turns out, I didn't fully understand the entire mechanism for implementing aggregation. Turns out that selection a method other than Group By replaces the handler with NumericField that essentially ignores the existing handler and it assumes that a field is involved. There are two ways to address this. The more complicated way, and possibly better, is to come up with a NumericField replacement and change how the handler is changed. The replacement could keep the details of the original field support in place. The other alternative is to put any support for aggregation into the desired plugin.
I chose the latter with the Views Raw SQL #15023002 patch #5 π the Value is lost with Aggregation Needs review . This essentially keeps the Group By setting but hides it so the NumericField substitution does not occur. The aggregation support is handled by replacing the options form selection with a new one and using the value in the aggregation support handled by the original field support.
For Views Raw SQL, this solution works for all of the field types including field, filter, sort and argument.
The solution I presented here does not really address the issue as it is trying to adjust changes imposed by NumericField. Assuming either approach above, the need for an aggregation override is not needed. If this is the case then this issue should be closed.
- Status changed to Needs work
over 1 year ago 10:22pm 25 April 2023 The Needs Review Queue Bot β tested this issue. It fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".
This does not mean that the patch needs to be re-rolled or the MR rebased. Read the Issue Summary, the issue tags and the latest discussion here to determine what needs to be done.
Consult the Drupal Contributor Guide β to find step-by-step guides for working with issues.