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

当使用Statement不同sql执行多次execute方法,sql监控只会有一条sql记录 #4921

Closed
huangguangshan opened this issue Sep 4, 2022 · 2 comments
Labels
Milestone

Comments

@huangguangshan
Copy link
Contributor

问题说明:当使用Statement不同sql执行多次execute方法,sql监控只会有一条sql记录。伪代码如下:
Connection connection = dataSource.getConnection();
Statement stmt= connection.createStatement();
stmt.execute("create table account0(accno varchar(20),customer varchar(30),balance int)");
stmt.execute("insert into account0 values('20','user1',9)");
stmt.close();
connection.close();
此时sql监控只有create语句的sql。但是执行数、执行时间等都会进行相应的累加。

@huangguangshan
Copy link
Contributor Author

附上该问题修复pr链接 #4922

@wenshao wenshao added this to the 1.2.12 milestone Sep 5, 2022
@wenshao wenshao added the Bug label Sep 10, 2022
@wenshao
Copy link
Member

wenshao commented Sep 10, 2022

https://github.com/alibaba/druid/releases/tag/1.2.12
druid-1.2.12版本已发布,请帮忙用新版本验证

@wenshao wenshao closed this as completed Sep 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants