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

feat(go/adbc/driver/snowflake): add query tag option #2484

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

lidavidm
Copy link
Member

This lets you identify particular queries in the query history.

Fixes #1934.

This lets you identify particular queries in the query history.

Fixes apache#1934.
@lidavidm lidavidm marked this pull request as ready for review January 27, 2025 05:33
@lidavidm lidavidm requested a review from zeroshade as a code owner January 27, 2025 05:33
@github-actions github-actions bot modified the milestone: ADBC Libraries 17 Jan 27, 2025
Comment on lines +2268 to +2270
rdr, n, err := suite.stmt.ExecuteQuery(suite.ctx)
suite.Require().NoError(err)
defer rdr.Release()
Copy link
Member

Choose a reason for hiding this comment

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

i doubt it, but is there any way we can test / confirm that the tag is being propagated for the query?

Copy link
Member Author

Choose a reason for hiding this comment

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

That is the test: we query the query history with the tag and make sure it comes back

Copy link
Member

Choose a reason for hiding this comment

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

Ah i get it. I missed that's what the query below was doing. Makes sense! Thanks!

Comment on lines +115 to +117
#: An identifier for a query/queries that can be used to find the query in
#: the query history. Use a blank string to unset the tag.
QUERY_TAG = "adbc.snowflake.statement.query_tag"
Copy link
Member

Choose a reason for hiding this comment

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

did we ever update the docs to point out the difference between statement options and connection options etc.?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't think so. In general I'd like to improve the docs...

Copy link
Member Author

Choose a reason for hiding this comment

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

@lidavidm lidavidm merged commit f37fd5c into apache:main Jan 28, 2025
67 of 69 checks passed
@lidavidm lidavidm deleted the gh-1934 branch January 28, 2025 00:14
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.

Add in a means to pass session_parameters onto Snowflake Driver
2 participants