Fixed what I believe was a mistake.

git-svn-id: svn+ssh://svn.code.sf.net/p/firebird/code/firebird/trunk@59242 65644016-39b1-43b1-bf79-96bc8fe82c15
Reworked one of my prior commits that caused regression CORE-4360: Select from derived table which contains GROUP BY on field with literal value returns wrong result.

git-svn-id: svn+ssh://svn.code.sf.net/p/firebird/code/firebird/trunk@59243 65644016-39b1-43b1-bf79-96bc8fe82c15