count the number of patients who have had a alveolar-arterial gradient test done since 5 years ago.
select count( distinct admissions.subject_id ) from admissions where admissions.hadm_id in ( select labevents.hadm_id from labevents where labevents.itemid in ( select d_labitems.itemid from d_labitems where d_labitems.label = 'alveolar-arterial gradient' ) and datetime(labevents.charttime) >= datetime(current_time,'-5 year') )