mysql - Separate 30 into three batches -


enter image description here

there 30 students in classroom. want separate them 3 batches using mysql query in jsp.

initially did using below query

connection = drivermanager.getconnection(connectionurl, "root", "student"); string querystring = "update student set batch=?,exam=? studentid='"+studentid+"'  "; pstatement = connection.preparestatement(querystring); pstatement.setstring(1, batch); pstatement.setstring(2, exam); 

i don't have privileges comment check if ui sending second student info correctly. query looks ok me.


Comments

Popular posts from this blog

android - Why am I getting the message 'Youractivity.java is not an activity subclass or alias' -

python - How do I create a list index that loops through integers in another list -

c# - “System.Security.Cryptography.CryptographicException: Keyset does not exist” when reading private key from remote machine -