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

Allow Query() to accept parameterized SQL values #6

Merged
merged 2 commits into from
Jul 14, 2021

Conversation

zacharyvoase
Copy link
Contributor

This way we can benefit from Go's built-in SQL escaping routines without having to do DB-specific string escaping in the load testing script itself.

@imiric
Copy link
Contributor

imiric commented Jun 29, 2021

Hey, thanks for this!

LGTM, but could you add a usage example of it in the tests/ directory? Just for SQLite would be fine.

I'd like to eventually turn these into proper tests and hook up CI here, but well, priorities :)

@zacharyvoase
Copy link
Contributor Author

Done, I added it for all three examples (I'm currently using it successfully with postgres, actually).

Copy link
Contributor

@imiric imiric left a comment

Choose a reason for hiding this comment

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

Great, thank you very much!

@imiric imiric merged commit f594942 into grafana:master Jul 14, 2021
@zacharyvoase
Copy link
Contributor Author

Thank you so much!

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.

None yet

2 participants