Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- select disease.condition_id, (disease::float/total::float) as prevalence
- from (
- select condition_id, count(person_id)
- from a.condition
- where condition_id=316139
- group by condition_id
- ) as disease
- join (
- select count(distinct person_id) as total
- from a.person
- )as total;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement