File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JDBC and Relational Databases and the fly likes Row Lock and Prevent Read Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Row Lock and Prevent Read" Watch "Row Lock and Prevent Read" New topic

Row Lock and Prevent Read

Rudolf Castelino

Joined: Oct 30, 2002
Posts: 18

Is there any way to lock a row in a table in a way that prevents any other thread from reading the row from the table ?

Jeanne Boyarsky
author & internet detective

Joined: May 26, 2003
Posts: 33130

It depends on the database.

What are you trying to accomplish by preventing other users from accessing that row? Is it transaction support or something else?

[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
I agree. Here's the link:
subject: Row Lock and Prevent Read
It's not a secret anymore!