dbTalk Databases Forums  

realising a "progressbar" for a long working package

comp.databases.oracle.misc comp.databases.oracle.misc


Discuss realising a "progressbar" for a long working package in the comp.databases.oracle.misc forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Norbert Winkler
 
Posts: n/a

Default realising a "progressbar" for a long working package - 02-10-2009 , 05:58 AM






Hi,

I've a package that generates some table records with some random chooses
(2-5%).
But the steps to generates the random sample need a little bit time.
I've tried to optimize it by using all indexes (by separtating it in more
steps with several new tables) and so far I think I couln't improve it in
speed.
Now I would like it that my application reports me the step it is working
on.
1. The simplest way - but brute force - seems me to start the package work
in a separated thread, and use a timer to start count-queries about the
filled tables, a commit after each step wouldn't be a problem.
2. Or I split the work in more procedures that I call step by step in my
application. But the the logic goes to the application.
3. To use a package report-variable isn't possible (I think) because my
threads need different sessions.

Any suggestions are welcome!

--
Norbert
Oracle9i Enterprise Edition Release 9.2.0.8.0 64Bit

Reply With Quote
  #2  
Old   
ddf
 
Posts: n/a

Default Re: realising a "progressbar" for a long working package - 02-10-2009 , 08:51 AM






On Feb 10, 5:58*am, Norbert Winkler <norbert.winkl... (AT) gmx (DOT) de> wrote:
Quote:
Hi,

I've a package that generates some table records with some random chooses
(2-5%).
But the steps to generates the random sample need a little bit time.
I've tried to optimize it by using all indexes (by separtating it in more
steps with several new tables) and so far I think I couln't improve it in
speed.
Now I would like it that my application reports me the step it is working
on.
1. The simplest way - but brute force - seems me to start the package work
in a separated thread, and use a timer to start count-queries about the
filled tables, a commit after each step wouldn't be a problem.
2. Or I split the work in more procedures that I call step by step in my
application. But the the logic goes to the application.
3. To use a package report-variable isn't possible (I think) because my
threads need different sessions.

Any suggestions are welcome!

--
Norbert
Oracle9i Enterprise Edition Release 9.2.0.8.0 64Bit
You should probably look into the possibility of using the V
$SESSION_LONGOPS view.


David Fitzjarrell


Reply With Quote
  #3  
Old   
Norbert Winkler
 
Posts: n/a

Default Re: realising a "progressbar" for a long working package - 02-11-2009 , 02:33 AM



Am Tue, 10 Feb 2009 06:51:42 -0800 (PST) schrieb ddf:

Quote:
V
$SESSION_LONGOPS
Thanks a lot. I've found some very good articles, but I didn't found an
answer, if i.e. 2SELECT * FROM v$session_longops" is able to done from an
other session.

--
Norbert
Oracle9i Enterprise Edition Release 9.2.0.8.0 64Bit


Reply With Quote
  #4  
Old   
ddf
 
Posts: n/a

Default Re: realising a "progressbar" for a long working package - 02-11-2009 , 08:05 AM



On Feb 11, 2:33*am, Norbert Winkler <norbert.winkl... (AT) gmx (DOT) de> wrote:
Quote:
Am Tue, 10 Feb 2009 06:51:42 -0800 (PST) schrieb ddf:

V
$SESSION_LONGOPS

Thanks a lot. I've found some very good articles, but I didn't found an
answer, if i.e. 2SELECT * FROM v$session_longops" is able to done from an
other session.

--
Norbert
Oracle9i Enterprise Edition Release 9.2.0.8.0 64Bit
Yes, it is. It's how Oracle's java-based Enterprise Manager provides
such a display.


David Fitzjarrell


Reply With Quote
  #5  
Old   
Gints Plivna
 
Posts: n/a

Default Re: realising a "progressbar" for a long working package - 02-13-2009 , 04:48 PM



On 10 Febr., 13:58, Norbert Winkler <norbert.winkl... (AT) gmx (DOT) de> wrote:
Quote:
Hi,

I've a package that generates some table records with some random chooses
(2-5%).
But the steps to generates the random sample need a little bit time.
I've tried to optimize it by using all indexes (by separtating it in more
steps with several new tables) and so far I think I couln't improve it in
speed.
Now I would like it that my application reports me the step it is working
on.
You can find quite detailed info about v$session_longops in my article
here http://www.gplivna.eu/papers/v$session_longops.htm it also
contains a link to another article explaining dbms_application_info,
which allows programmatically set v$session_longops values.

Gints Plivna
http://www.gplivna.eu


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.