- πΊπΈUnited States mortona2k Seattle
I encountered this issue, looks like I have an aggregated table with a sum on a column that has no values.
This patch fixes the warnings. It's just checking isset($result_row->_relationship_entities[$relationship]) before using the value.
- πΊπΈUnited States tr Cascadia
OK I screwed up the rebasing to a new branch, but it's fixed now. The new MR has the same changes as @plopesc posted in #1, but it's now on the current 2.1.x branch.
Adding an isset() to make an error go away is something I really don't like to do. Because for example in this case $source never gets a value, which may cause problems further down the line, and even if it doesn't cause a problem having to check a value with isset() tells me that there's something wrong in the code before we get to that point. Shouldn't we know at this point whether the relationship exists? Why are we trying to do something with it?
- πΊπΈUnited States tr Cascadia
Also, see π Trouble calculating column sum on view with active views group_by (aggregation) Postponed: needs info which makes a very similar change for a different reason.