Store a query
Stores a new query, or updates an existing query on the system.
Path Parameters
- Type: string ·qualified
_query _name requiredThe (fully qualified) name of the query to be executed, in a format of
[{namespace}::]{query-name}.The (fully qualified) name of the query (when is registered as a stored query), in a format of
[{namespace}::]{query-name}. Thenamespaceprefix is optional, and when used it should be in a form of a reverse domain name.
Query Parameters
- Type: stringquery
_type Parameter indicating the query language/type.
Body
required
application/json
Responses
- 400
400 Bad Requestis returned when the server was unable to store the query. This could be due to incorrect request body (could not be parsed, etc), unknown query type, etc.
Request Example for put/definition/query/{qualified_query_name}
curl https://cataniamc.prod.cadasto.com/v1/definition/query/org.openehr::compositions \
--request PUT \
--header 'Content-Type: text/plain' \
--data 'SELECT c FROM
EHR e
CONTAINS COMPOSITION c[openEHR-EHR-COMPOSITION.encounter.v1]
CONTAINS OBSERVATION obs[openEHR-EHR-OBSERVATION.blood_pressure.v1]
WHERE
obs/data[at0001]/events[at0006]/data[at0003]/items[at0004]/value/magnitude >= $systolic_bp'
No Body