Subject Migrating Interbase to Firebird Subquery in Select Clause
Author mthendley
When using interbase, I used the following query:

SELECT in_inDate,
COUNT(*) AS HowMany,
(SELECT SUM(in_MoneyColl) FROM InDetail ID
WHERE IM.InvMaster_ID = ID.InvMaster_ID) AS Amt
FROM InvMaster IM
WHERE IM.inm_InvState = 2
AND inm_InvDate >= :BeginDate
AND inm_invDate < :EndDate
GROUP BY inm_InvDate

Firebird will not allow this since the subquery is not an aggregate
function and not in the GROUP BY clause. Any suggestions on how to
migrate this query over to Firebird?
Thanks