Naomi,
>No, doesn't work with HAVING clause.
Just in case, I would point out you have a spelling mistake in your having clause
>>SELECT ... ;
>>, MAX(Trans.yReferral_balance_amount)
yReferral_balance_amount;
>>...
>>GROUP BY 1;
> having yCurrent_balance_amount <>
yRefferal_Balance_amount - nvl(yTotalPayments,0)
>>into cursor curBalances
"The five senses obstruct or deform the apprehension of reality."
Jorge L. Borges?
"Premature optimization is the root of all evil in programming."
Donald Knuth, repeating C. A. R. Hoare
"To die for a religion is easier than to live it absolutely"
Jorge L. Borges