JDBC returning empty result set

前端 未结 14 1885
醉话见心
醉话见心 2020-12-15 06:15

I\'m using JDBC for very simple database connectivity.

I have created my connection/statement and executed a query. I check the query object of the statement in the

14条回答
  •  遥遥无期
    2020-12-15 06:41

    The same happened to me. I was using SQL Developer to insert test data into my database and test-reading that using JDBC. But all I got was an empty result-set. I could get the column names and all, but had a problem with reading data. As pointed out by dpsthree earlier, I disconnected from the SQL Developer IDE and then it asked me to Commit upon exiting.

    Voila! The problem was that the changes to the databases using the insert command weren't committed.

    For SQL Developer this is located at Preferences > Database > Advanced > Autocommit

    This solved my problem.

提交回复
热议问题