michoel
CASE WHEN trunc({today})-{trandate} between 61 and 90 then {amountremaining} * DECODE({type}, 'Payment', -1, 'Credit Memo', -1, 1)) END