Show Password


UNIX for Beginners Questions & Answers

If you're not sure where to post a Unix or Linux question, post it here. All unix and Linux beginners welcome in this forum!

Suggestion in Autosys job


👤 Login to reply
Thread Tools Search this Thread Display Modes
Old 10-10-2017
vasuvv vasuvv is offline
Registered User
Join Date: Apr 2012
Last Activity: 8 May 2018, 6:07 AM EDT
Posts: 32
Thanks: 8
Thanked 0 Times in 0 Posts
Suggestion in Autosys job


I am new to Unix and Autosys. I have written Oracle query. Now I would like to create Autosys job. below is the requirement.
  1. Send in email every 30 minutes from 11 to 4:00 PM. E-mail should only be sent ONLY when below Query have data return.
  2. Email format:
    • To: ,
    • From: ,
    • Email Subject: Data List
    • Email content:

select ts.sup_num, ts.s_add_num, 

ts.ind_qty, ts.total_qty, tb.b_qty, tt.tri_qty ,
case when ts.total_qty-tb.b_qty > tt.tri_qty then tt.tri_qty
else ts.total_qty-tb.b_qty end as rls_qty
select sup_num, s_add_num, count(*) , abs(sum(sh_qty)) as total_qty , LISTAGG(sh_qty, ',') WITHIN GROUP (ORDER BY updt_last_tmstp ) as ind_qty
from p_sls_trn where trunc(trans_dt) = '16-aug-2017' and dc_cd='C' and brc_cd='002'
group by s_add_num ,sup_num
) pts,
( select s_add_num, abs(settlement_dt_qty) as b_qty from tash where brc_cd||act_cd||TYPE_act_cd||act_nbr = '120000000987'
) tsh_box,
( select s_add_num, abs(settlement_dt_qty) as tri_qty from tash where brc_cd||act_cd||TYPE_act_cd||act_nbr in ('120000000087','120000009874')
where ts.s_add_num = tb.s_add_num and ts.s_add_num = tt.s_add_num
and ts.total_qty > tb.b_qty and tt.tri_qty > 0 ;

Can you please advise to create a job.


Last edited by vasuvv; 10-10-2017 at 06:07 AM.. Reason: bakunin changed [/code] to [code]; rbatte1 formatted lists
Sponsored Links
Old 10-11-2017
arunkumar_mca arunkumar_mca is offline
Registered User
Join Date: Oct 2004
Last Activity: 22 June 2018, 11:25 AM EDT
Posts: 416
Thanks: 81
Thanked 2 Times in 2 Posts
Assuming you know how to create job in autosys.

Step1 : Create a script which will execute the query and populate it to a file. If the file is having more that one record you can execute a mailx to send the email

Step2: Create a job and make that to run every 30 min using the autosys start_time parameter

Let me know if you need more details
Sponsored Links
👤 Login to reply

« Previous Thread | Next Thread »
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
OS suggestion daWonderer UNIX for Dummies Questions & Answers 2 03-23-2012 03:40 AM
Autosys: How to change a machine name in Autosys JIL. tp2115 UNIX for Dummies Questions & Answers 0 08-10-2011 11:02 AM
suggestion on awk Muthuraj K Shell Programming and Scripting 2 04-22-2010 06:29 AM
Documentation and books on Autosys Job Control Tool from Autosys gram77 UNIX for Advanced & Expert Users 0 11-10-2007 05:24 AM
Need your suggestion please.. unknown2205 Shell Programming and Scripting 1 11-21-2005 01:45 AM

All times are GMT -4. The time now is 09:17 PM.

Unix & Linux Forums Content Copyrightę1993-2018. All Rights Reserved.