🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: JDBC: all 10 questions

Quiz: JDBC · Question 7 of 10

What does executeUpdate() return for an UPDATE statement?

What does executeUpdate() return for an UPDATE statement?

  1. A.A ResultSet
  2. B.The number of rows changed
  3. C.true or false
  4. D.The new primary key
Answer & explanation

Correct answer: The number of rows changed

executeUpdate is for INSERT/UPDATE/DELETE and returns the affected row count.

Can you get the rest right without peeking?

Take the timed Quiz: JDBC quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →