Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I was wondering how many statements or preparedstatements can be opened per connection at the same time. I don't really understand how would it work if multiple statements get executed and multiple resultssets are retrieved. Links of resources with details would be helpful.

Thanks

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
282 views
Welcome To Ask or Share your Answers For Others

1 Answer

Multiple statements can be created and used on the same connection, but only one resultset at once can be created and used on the same statement. If you create/open another one by the same statement, then any previously opened resultset will be implicitly closed, leading to "ResultSet closed" exceptions on any attempt to access it.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...