阅读背景:

ResultSet定位不正确,我不知道究竟在哪里调用next()

来源:互联网 

I've seen a lot questions like this, but none of them has an answer I need. I have created a prepared statement which will update my table Tickets. Now to the method buyTickets() I give parameters of CustomerId (knr), PerformanceId(aid) and No. of Ticekts to buy (anzTickets). I have to loop through my Query and for every ticket (number of wanted tickets - anzTickets) I have to call prepared Statement. But I got an error which says that ResultSet is not properly positioned. I'm not really sure where and how to call next() so that preparedStatement can be executed in each row? Here is my code :I've seen a lot questions like this, but none o




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: