Can I write a Select query to update the data too Can I write a Select query under a jdbc connection ,having a resultset object and which would update the records on just passing the select query them in my sql.
This is not possible, at least not with plain JDBC. 

But, an ORM might give you what you are looking for. However, the use of ORMs is controversial. Have a look at https://stackoverflow.com/questions/452385/what-java-orm-do-you-prefer-and-why for an interesting collection of opinions. You can find a few example ORMs in there too.