Stream: implementers
Topic: Search for period
Alexander Henket (May 13 2019 at 09:29):
When I query for period=gt2019-01-01:
- Does data match that does not have the requested period specified, or can the query only match when the period exists? I expect data without a period to match.
- Does data match that has period.start=2019-01-01 without period.end? I expect yes because the period is active after given date
- Does data match that has period.start=2019-01-01 and period.end=2019-02-02. I expect yes as the period at least partly overlaps with the search parameter.
Lloyd McKenzie (May 13 2019 at 14:42):
Data without a period won't match. (Imagine searching a FamilyMemberHistory whose deceasedRange was unspecified). A missing period can has easily be assumed to have "not started yet" as it can "already done".
Yes for the other two.
Alexander Henket (May 13 2019 at 15:37):
The parameter in this case is a custom search parameter. Does a search parameter inherit the same rules, or can you specify what the parameter will do in absence of data?
Lloyd McKenzie (May 13 2019 at 15:39):
The general rule is you need to use :missing if you want to match on missing data
John Moehrke (May 13 2019 at 15:52):
general rule I understand.. but in the case of clinical care periods it seems more reasonable to have a logical meaning of missing data. There is a logical meaning of missing query parameter, but the counter argument for missing data is not stated.
Lloyd McKenzie (May 13 2019 at 15:58):
If there's a "meaning if missing", that could be taken into account as part of the search. Otherwise, no.
John Moehrke (May 13 2019 at 16:13):
I tried to express in a CR the problem with open-ended queries (only less than a high value, or only greater than a low value). It is these that are less clear, right?
I am not sure there needs to be any different meaning if missing for Period datatype values. The Period datatype is clear about missing start means unknown. What is not made clear is that for query purposes an unknown start should be viewed as starting at zero time. Seems only thing missing is this query behavior relative to a missing start value on a Period datatype. this kind of guidance would be better than no guidance. this kind of guidance would return more results than might be needed, but would not miss results that should be seen... This is the precedence found in XDS/XCA regarding this.
Other timing datatypes are less confusing.
Lloyd McKenzie (May 13 2019 at 17:08):
missing start with an end means start exists but is unknown. However, if you're missing both start and end, that doesn't tell you that there has ever been a start.
Brian Postlethwaite (Jun 26 2019 at 10:46):
You would probably consider other properties like status in those cases (my server doesn't)
Brian Postlethwaite (Jun 26 2019 at 10:47):
My server will however assume that no start date would match the rules above.
Last updated: Apr 12 2022 at 19:14 UTC