Skip to content

Conversation

@stanvanrooy
Copy link
Contributor

This is a follow up for the previous PR. This makes it possible to query with both single- and multi-valued variables.

After this PR, the following query in Grafana:

SELECT * FROM backend WHERE application_name IN ($application) OR duration_ms IN ($duration) OR sub = '$sub'

In to:

SELECT * FROM backend WHERE application_name IN ('Elfskot.Api','Elfsquad.ConfiguratorApi','Elfsquad.OdataApi') OR duration_ms IN ('30', '8') OR sub = '1ff96bd8-53d8-4214-85b9-08da00dc987f'

The WHERE IN (x, y, z) with single quotes seems to work for both numbers & strings. The logic in the formatter might need to be improved for more complex data types.

Copy link
Member

@nitisht nitisht left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please take a look at the conflict @stanvanrooy ?

Signed-off-by: Stan van Rooy <[email protected]>
@nitisht nitisht merged commit f5b2453 into parseablehq:main Aug 31, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Aug 31, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants