{"action":"created","issue":{"url":"https://api.github.com/repos/openhealthcare/opal/issues/296","labels_url":"https://api.github.com/repos/openhealthcare/opal/issues/296/labels{/name}","comments_url":"https://api.github.com/repos/openhealthcare/opal/issues/296/comments","events_url":"https://api.github.com/repos/openhealthcare/opal/issues/296/events","html_url":"https://github.com/openhealthcare/opal/issues/296","id":106950895,"number":296,"title":"Patient subrecords are not extracted for all episodes when the patient has multiple admissions","user":{"login":"davidmiller","id":17229,"avatar_url":"https://avatars.githubusercontent.com/u/17229?v=3","gravatar_id":"","url":"https://api.github.com/users/davidmiller","html_url":"https://github.com/davidmiller","followers_url":"https://api.github.com/users/davidmiller/followers","following_url":"https://api.github.com/users/davidmiller/following{/other_user}","gists_url":"https://api.github.com/users/davidmiller/gists{/gist_id}","starred_url":"https://api.github.com/users/davidmiller/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidmiller/subscriptions","organizations_url":"https://api.github.com/users/davidmiller/orgs","repos_url":"https://api.github.com/users/davidmiller/repos","events_url":"https://api.github.com/users/davidmiller/events{/privacy}","received_events_url":"https://api.github.com/users/davidmiller/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/openhealthcare/opal/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/openhealthcare/opal/milestones/13","html_url":"https://github.com/openhealthcare/opal/milestones/0.5","labels_url":"https://api.github.com/repos/openhealthcare/opal/milestones/13/labels","id":1290014,"number":13,"title":"0.5","description":null,"creator":{"login":"davidmiller","id":17229,"avatar_url":"https://avatars.githubusercontent.com/u/17229?v=3","gravatar_id":"","url":"https://api.github.com/users/davidmiller","html_url":"https://github.com/davidmiller","followers_url":"https://api.github.com/users/davidmiller/followers","following_url":"https://api.github.com/users/davidmiller/following{/other_user}","gists_url":"https://api.github.com/users/davidmiller/gists{/gist_id}","starred_url":"https://api.github.com/users/davidmiller/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidmiller/subscriptions","organizations_url":"https://api.github.com/users/davidmiller/orgs","repos_url":"https://api.github.com/users/davidmiller/repos","events_url":"https://api.github.com/users/davidmiller/events{/privacy}","received_events_url":"https://api.github.com/users/davidmiller/received_events","type":"User","site_admin":false},"open_issues":2,"closed_issues":4,"state":"open","created_at":"2015-09-04T11:38:28Z","updated_at":"2015-11-09T11:14:12Z","due_on":null,"closed_at":null},"comments":2,"created_at":"2015-09-17T10:00:23Z","updated_at":"2015-11-09T11:35:09Z","closed_at":null,"body":"e.g. episode id 3114 is patient id 2954 - patient id 2954 has three episodes - only one of which is in demographics.csv\r\n\r\nThis is caused by the mapping of episode ids to patient ids here: \r\nhttps://github.com/openhealthcare/opal/blob/0d7a3a785b36a90806792d651394604d0c29c112/opal/core/search/extract.py#L65 - which is essentially the correct idea but the wrong way round.\r\n\r\n/cc @michaeledwardmarks who found this in the wild."},"comment":{"url":"https://api.github.com/repos/openhealthcare/opal/issues/comments/155036523","html_url":"https://github.com/openhealthcare/opal/issues/296#issuecomment-155036523","issue_url":"https://api.github.com/repos/openhealthcare/opal/issues/296","id":155036523,"user":{"login":"fredkingham","id":2175455,"avatar_url":"https://avatars.githubusercontent.com/u/2175455?v=3","gravatar_id":"","url":"https://api.github.com/users/fredkingham","html_url":"https://github.com/fredkingham","followers_url":"https://api.github.com/users/fredkingham/followers","following_url":"https://api.github.com/users/fredkingham/following{/other_user}","gists_url":"https://api.github.com/users/fredkingham/gists{/gist_id}","starred_url":"https://api.github.com/users/fredkingham/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fredkingham/subscriptions","organizations_url":"https://api.github.com/users/fredkingham/orgs","repos_url":"https://api.github.com/users/fredkingham/repos","events_url":"https://api.github.com/users/fredkingham/events{/privacy}","received_events_url":"https://api.github.com/users/fredkingham/received_events","type":"User","site_admin":false},"created_at":"2015-11-09T11:35:09Z","updated_at":"2015-11-09T11:35:09Z","body":"I believe so, I think you fixed it!\n\nOn 9 November 2015 at 11:14, David Miller <notifications@github.com> wrote:\n\n> @fredkingham <https://github.com/fredkingham> - I have a feeling this got\n> fixed ?\n>\n> —\n> Reply to this email directly or view it on GitHub\n> <https://github.com/openhealthcare/opal/issues/296#issuecomment-155031120>\n> .\n>\n"}}