Re: Table update is taking too much time

  • From: Brent Day <coloradodba@xxxxxxxxx>
  • To: ramukam1983@xxxxxxxxx
  • Date: Sun, 29 May 2016 20:04:10 -0600

I forgot a couple of items.

Make sure the execute immediate statements have proper begin end exception
handling, something like

BEGIN
   execute immediate 'alter index....'
exception
   when others then
      log the error
end;

Also this moves the truncate and constraint changes into the pl/sql block,
remove them from the sh script before the procedure call.

Brent


On Sun, May 29, 2016 at 8:00 PM, Brent Day <coloradodba@xxxxxxxxx> wrote:

Ashoke,

Here is an example of what you could do to improve the code. I took out
all of the logging code and you would want to enhance this to include the
capture of exceptions in each of the forall blocks to make this code
better. There are also other ways to accomplish this.



Other related posts: