Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NGSI-LD] Test query language for NGSI-LD entities #343

Open
djs0109 opened this issue Oct 29, 2024 · 1 comment
Open

[NGSI-LD] Test query language for NGSI-LD entities #343

djs0109 opened this issue Oct 29, 2024 · 1 comment
Labels
feature request Request a potential feature NGSI-LD

Comments

@djs0109
Copy link
Contributor

djs0109 commented Oct 29, 2024

Test query language for get_entities endpoints.

official examples from spec v1.3.1

from section 4.9

# Example 1: Query checking if temperature is equal to 20
temperature_check = "temperature == 20"

# Example 2: Query checking if brand name is not "Mercedes"
brand_check = 'brandName != "Mercedes"'

# Example 3: Query checking if the parked status matches a specific identifier
is_parked_check = 'isParked == "urn:ngsi-ld:OffStreetParking:Downtown1"'

# Example 4: Query encoded as HTTP Query String with multiple conditions
http_query_example = "?q=speed > 50; brandName != Mercedes"

# Example 5: Query checking if entities have the attribute isMonitoredBy
is_monitored_check = "isMonitoredBy"

# Example 6: Complex query using logical OR and AND
complex_query_1 = "((speed > 50 | rpm > 3000); brandName == 'Mercedes')"

# Example 7: Query combining temperature range and capacity conditions with logical OR
complex_query_2 = "(temperature >= 20; temperature <= 25) | capacity <= 10"

# Example 8: Query for checking attribute path for observedAt time
observed_at_query = "temperature.observedAt >= '2017-12-24T12:00:00Z'"

# Example 9: Query for a specific city within a JSON structure in address property
city_query = 'address[city] == "Berlin"'

# Example 10: Query for a specific air quality particulate level in a nested JSON structure
particulate_query = "sensor.rawdata[airquality.particulate] == 40"
@djs0109 djs0109 added feature request Request a potential feature NGSI-LD labels Oct 29, 2024
@djs0109 djs0109 changed the title Test query language for NGSI-LD entities [NGSI-LD] Test query language for NGSI-LD entities Oct 29, 2024
@djs0109
Copy link
Contributor Author

djs0109 commented Oct 29, 2024

@SystemsPurge could you take over this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Request a potential feature NGSI-LD
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

1 participant