ตั้งแต่ 2 ปีที่แล้ว การทดสอบทางจุลชีววิทยาที่พบบ่อยที่สุดสามอันดับแรกที่สั่งให้ผู้ป่วยภายในเดือนเดียวกันหลังจากได้รับเอ็นโดสก์เอานิ่วน้ำดีคืออะไร? ไม่จำเป็นต้องใช้ตารางทั้งหมด
since 2 years ago, what are the top three most frequent microbiology tests ordered for patients within the same month after receiving the endosc remove bile stone?It is not neccessary to use all the tables.
 labevents:  row_id [ number]  subject_id [ number]  hadm_id [ number]  itemid [ number]  charttime [ time]  valuenum [ number]  valueuom [ text] 
SELECT t3.spec_type_desc FROM (SELECT t2.spec_type_desc, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT admissions.subject_id, procedures_icd.charttime FROM procedures_icd JOIN admissions ON procedures_icd.hadm_id = admissions.hadm_id WHERE procedures_icd.icd9_code = (SELECT d_icd_procedures.icd9_code FROM d_icd_procedures WHERE d_icd_procedures.short_title = 'endosc remove bile stone') AND DATETIME(procedures_icd.charttime) >= DATETIME(CURRENT_TIME(), '-2 year')) AS t1 JOIN (SELECT admissions.subject_id, microbiologyevents.spec_type_desc, microbiologyevents.charttime FROM microbiologyevents JOIN admissions ON microbiologyevents.hadm_id = admissions.hadm_id WHERE DATETIME(microbiologyevents.charttime) >= DATETIME(CURRENT_TIME(), '-2 year')) AS t2 ON t1.subject_id = t2.subject_id WHERE t1.charttime < t2.charttime AND DATETIME(t1.charttime, 'start of month') = DATETIME(t2.charttime, 'start of month') GROUP BY t2.spec_type_desc) AS t3 WHERE t3.c1 <= 3