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

Quote and join multiple variables #118

Merged
merged 4 commits into from
Nov 30, 2021
Merged

Quote and join multiple variables #118

merged 4 commits into from
Nov 30, 2021

Conversation

andresmgot
Copy link
Contributor

Fixes #107

As we do in athena, quote and join variables if they have multiple values.

Screenshot from 2021-11-26 15-32-58

@andresmgot andresmgot requested review from ryantxu, a team, sarahzinger and vickyyyyyyy and removed request for a team November 26, 2021 14:34
@@ -55,6 +55,21 @@ export class DataSource extends DataSourceWithBackend<TimestreamQuery, Timestrea
return query.rawQuery ?? '';
}

private interpolateVariable = (value: string | string[]) => {
Copy link
Member

Choose a reason for hiding this comment

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

nice, I'm guessing this is maybe something that can be shared in the sdk or maybe elsewhere if we are reusing this in multiple plugins?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes! I have a point in the design document to try to use a common class that cover this

src/DataSource.ts Outdated Show resolved Hide resolved
src/DataSource.ts Show resolved Hide resolved
@andresmgot andresmgot merged commit 5228959 into main Nov 30, 2021
@andresmgot andresmgot deleted the multipleVariables branch February 23, 2022 09:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Selecting multiple values in a variable results in malformed query
2 participants