oracle8.1.6 and sysdate-r.refund_date <= 1 and sysdate-r.refund_date <= 7 and months_between(sysdate,r.refund_date) <= 1