Hi,
I am trying to call executeUpdate() on a preparedStatement.It hangs and wont give me any output.I know for sure its executeUpdate that's a problem.
Help me.Even when I use the commented code it does not work!
Thanks
What does "give me output" actually mean? If you aren't seeing anything from System.out.println(password) then maybe that line of code isn't being executed. Or maybe you aren't looking in the right place.
On the other hand it might mean something about the String being returned from the method. However you haven't shown any code which uses that method so maybe that code isn't working the way you think it should.
Now I am able to insert only one record upon restarting my PC and subsequently it hangs at the executeUpdate call. Please help am stuck here.
Nickolas,
There are no locks on the table I checked block=0 and request =0 on all ids.
Paul,
The System.out.print(password) prints out.By output i meant the return string from the method e.g You created a User.My TestClass is alright and calls addUser without errors.
The code is working now.First am checking if the tuple exists then insert.What was happening is that after inserting the record I would use sqlplus to delete that record and re-run without committing the delete transaction.
How can I commit my statements automatically? statement.setAutoCommit(true) did not do it.