It is currently 22 Nov 2017 11:13


Post new topic  Reply to topic  [ 4 posts ] 
Author Message
PostPosted: 07 Mar 2013 3:25 
Offline
Nouveau
Nouveau
User avatar

Joined: 06 Mar 2013 12:00
Posts: 1
Hi

we have recently upgraded Control-M to v7 with a postgres db.

I need a script to list out the top 10 long running jobs each day and also details of how to run it!

many thanks in advance

Helene


Top
   
 Post subject: Query on database
PostPosted: 22 Mar 2013 11:46 
Offline
Nouveau
Nouveau
User avatar

Joined: 18 Mar 2010 12:00
Posts: 31
Hi,
You can query the cmr_ajf table on the Control/M Server database.

SELECT applgroup,nodeid,memname,odate,startrun,endrun,jobname,applic, cast(endrun as bigint) - cast(startrun as bigint) as seconds_elapsed
FROM cmr_ajf order by seconds_elapsed desc LIMIT 10 ;

You can schedule the query just before the NDP and you have the top 10 long running jobs.

Hope it helps.

Fabrizio


Top
   
PostPosted: 30 Jun 2015 5:09 
Offline
Nouveau
Nouveau
User avatar

Joined: 12 Nov 2013 12:00
Posts: 14
Thanks Fabrizio,
But can you let me know the same on pgsql DB and Control-M server is on windows.

Thanks for the update..


Top
   
PostPosted: 03 Jul 2015 5:19 
Offline
Nouveau
Nouveau
User avatar

Joined: 12 Nov 2013 12:00
Posts: 14
fafa1975 wrote:
Hi,

You can query the cmr_ajf table on the Control/M Server database.



SELECT applgroup,nodeid,memname,odate,startrun,endrun,jobname,applic, cast(endrun as bigint) - cast(startrun as bigint) as seconds_elapsed

FROM cmr_ajf order by seconds_elapsed desc LIMIT 10 ;



You can schedule the query just before the NDP and you have the top 10 long running jobs.



Hope it helps.



Fabrizio



Hi,

Can you help out how to set it up on Windows through a bat file with an automated mail
my Controm DB on default PGSQL
I did it on unix with oracel db , but having problem in above environment....

Thanks,
Dablu


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 4 posts ] 

All times are UTC+01:00


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Limited
The site created by Franck YOT. Images, logo, content and trademarks about Control-M products are property of BMC Software.
All the comments are property of their posters. Images, logo, content and design are © copyright by Scheduler-Usage.com. All Rights Reserved