the first time when they visited the hospital last time patient 10539 received a dx ultrasound-thorax nec treatment?
select procedures_icd.charttime from procedures_icd where procedures_icd.icd9_code = ( select d_icd_procedures.icd9_code from d_icd_procedures where d_icd_procedures.short_title = 'dx ultrasound-thorax nec' ) and procedures_icd.hadm_id in ( select admissions.hadm_id from admissions where admissions.subject_id = 10539 and admissions.dischtime is not null order by admissions.admittime desc limit 1 ) order by procedures_icd.charttime asc limit 1