Created
February 23, 2026 02:13
-
-
Save tu-trinh-scale/abb750a63c4b90935144781ed6c88745 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| WITH threshold AS ( | |
| SELECT AVG("aCL IgM") AS avg_igm | |
| FROM Examination | |
| WHERE "aCL IgM" IS NOT NULL | |
| ) | |
| SELECT DISTINCT e.Symptoms | |
| FROM Examination e | |
| JOIN Patient p ON p.ID = e.ID | |
| CROSS JOIN threshold t | |
| WHERE p.Admission = '+' | |
| AND e."Examination Date" BETWEEN '1995-01-01' AND '1999-12-31' | |
| AND e.Thrombosis = '2' | |
| AND e."ANA Pattern" LIKE '%S%' | |
| AND e."aCL IgM" < t.avg_igm | |
| AND e.Symptoms IS NOT NULL; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment