Support SET ROLE
for clickhouse.Conn
#1391
jpugliesi
started this conversation in
Feature requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
We have a use case where we'd like to be able to dynamically set the connection
ROLE
prior to executing a query (and unset it after). Ex:This does not seem currently possible with the native/
clickhouse
clickhouse.Conn
, because it pools connections under the hood and does not expose an API to retrieve and use the same, stateful connection for multiple statements.It seems like the only way to achieve this is to use the
database/sql
driver'sBeginTx
to execute multiple statements on the same connection.Is there some way to support
SET ROLE
with the native/clickhouse
driver? If not, are there plans to support this functionality somehow?This relates to #772, where exposing connection pool's
acquire
(or hooks into connection acquire/release from the pool) would allow thisBeta Was this translation helpful? Give feedback.
All reactions