Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: PLEASE HELP!!
Scott wrote:
> Thank you Jim.
> I want to update the rows one by one, as I do not want to lock many
> rows that have the same selection criteria. It could be just 2 or 3
> rows at some point in time that I may be interested. Please point any
> link or pseudo code to achieve this.
>
> Thank you again.
>
>
> Jim Kennedy wrote:
> > "Scott" <sivaraman55_at_gmail.com> wrote in message
> > news:1129174103.377063.229830_at_f14g2000cwb.googlegroups.com...
> > > I using ORacle 10g and VB.NET and I like to lock the rows of a table
> > > based on some selection criteria and update the rows, one by one.
> > > What is the recommended approach and any links or pseudo code is
> > > appreciated.
> > > Please help.
> > >
> > > Thank you.
> > >
> > > Scotty.
> > >
> >
> > Run to the nearest book store and buy Tom Kyte's new book "Expert Oracle
> > Database Architecture: 9i and 10g Programming Techniques and Solutions".
> > While you are there get his other books. You can also access the full
> > documentation on line for free at otn.oracle.com. (You have to register,
> > but it is free and they don't spam you.)
> >
> > Updating rows one by one is slow by slow. If reasonably possible don't
> > do that update them all at the same time.
> >
> > Why do you want to lock the rows? What do you think locking the rows
> > will accomplish? The reason I ask is that different databases handle
> > different types of locking differently. What are you expecting and what
> > is the business need?
> > Jim
Note that UPDATE automatically locks each row updated, until you commit or roll back.
btw the convention in this group is to bottom-post.
William Robertson
http://Oracle-WTF.blogspot.com
Received on Sat Oct 15 2005 - 04:10:58 CDT
![]() |
![]() |