Sponsored Content
Top Forums Shell Programming and Scripting Need to extract jil file details in a excelsheet Post 302992676 by newbie_shell on Tuesday 28th of February 2017 01:07:34 PM
Old 02-28-2017
Need to extract jil file details in a excelsheet

I am very new to shell scripting.

I have a autosys jil file that looks like :--
Code:
/* ------------- JOB1 ------------------ */

insert_job: JOB1    job_type:  b
owner:     cm@pelonmuck
permission: gx,ge,wx,we,mx,me
date_conditions: 1
days_of_week: mo,tu,we,th,fr,su
start_time: "18:30"
box_success: s(SOME_JOB1) and s(SOME_JOB2) and s(SOME_JOB3)
box_failure: (f(SOME_JOB1) or f(SOME_JOB2)) & f(SOME_JOB3)
description: "pull files"
max_run_alarm: 15
alarm_if_fail: 1
timezone: US/Eastern


/* ------------- JOB2 ------------------ */

insert_job: JOB2    job_type:  c
box_name: SOME_BOX_NAME
command: /usr/bin/run /usr/cache/START_JOB
machine: machine@conti.com
owner:     cm@pelonmuck        
permission: gx,ge,wx,we,mx,me
days_of_week: sa,su
description: "pull all files"
max_run_alarm: 15
alarm_if_fail: 1
timezone: GMT

I need to create a shell script to get the output in a excelsheet/csv format like below:-

Code:
insert_job,machine,date_conditions,days_of_week,start_time,timezone,description,command,alarm_if_fail
JOB1,,1,mo,tu,we,th,fr,su,"18:30",US/Eastern,"pull files",,1
JOB2,machine@conti.com,,sa,su,,GMT,"pull all files",/usr/bin/run /usr/cache/START_JOB,1

Could you all pls help me to build this.


Moderator's Comments:
Mod Comment Please use CODE tags correctly as required by forum rules!

Last edited by RudiC; 02-28-2017 at 02:27 PM.. Reason: Changed ICODE to CODE tags.
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

execute a .jil file

Hi All, Could anyone suggest me as to how could we execute a .jil file. Thanks in advance. (1 Reply)
Discussion started by: OSD
1 Replies

2. Shell Programming and Scripting

execute a .jil file

hello all, Could anyone please suggest me as to how could we execute a .jil file. Thanks in advance for your help. (4 Replies)
Discussion started by: OSD
4 Replies

3. Shell Programming and Scripting

i want to extract details for particular file

Hi i have following file uuid ( RO) : 62701790-60da-dd9a-669d-a563aac1c435 host-uuid ( RO): 5f3f668d-a7c7-4e5f-a4a6-6e90fafb50ed sr-uuid ( RO): 62103d07-e0aa-acf3-2d9f-414ad3377bd0 device-config (MRO): location: /dev/xapi/block ... (6 Replies)
Discussion started by: bp_vardhaman
6 Replies

4. Shell Programming and Scripting

Help with excelsheet generation

Hi All, i have around 50 queries in sybase. We have a requirement where we need to write a unix script, which execute the query one by one & generate the excel sheet & send it to user. I have completed half of the part, where i am executing query one by one & putting the result into a .txt... (4 Replies)
Discussion started by: Amit.Sagpariya
4 Replies

5. Shell Programming and Scripting

Contents and details extract problem asking...

Input: length align type 5453 8666 + length align portion 5453 8666 + length align range 5453 5616 + length align name 5453 6121 + length align age 5617 6121 + length align name 7214 7404 + length ... (11 Replies)
Discussion started by: patrick87
11 Replies

6. Shell Programming and Scripting

need to parse the jil file into an excel file

Hi I have the following as input /* ----------------- backupJIL ----------------- */ insert_job: backupJIL job_type: c command: autorep -J ALL -q > /home/autosys/...p/autosys_jil_bk machine: machine owner: autosys@machine permission: gx,ge,wx,we date_conditions: 1 days_of_week:... (7 Replies)
Discussion started by: ramky79
7 Replies

7. Shell Programming and Scripting

Extract details from XML file

Hi , I have one xml file contains more than 60 lines. I need to extract some details from the file and store it in new file.Not the whole file Please find the xml file below: <?xml version="1.0" encoding="UTF-8"?> <DeploymentDescriptors xmlns="http://www.tibco.com/xmlns/dd"> ... (6 Replies)
Discussion started by: ckchelladurai
6 Replies

8. UNIX for Dummies Questions & Answers

at -l doesnt give details of the scheduled job. How to get the details?

I have scheduled couple of shell scripts to run using 'at' command. The o/p of at -l is: $ at -l 1320904800.a Thu Nov 10 01:00:00 2011 1320894000.a Wed Nov 9 22:00:00 2011 1320876000.a Wed Nov 9 17:00:00 2011 $ uname -a SunOS dc2prcrptetl2 5.9 Generic_122300-54 sun4u sparc... (2 Replies)
Discussion started by: superparticle
2 Replies

9. Shell Programming and Scripting

Perl : corrupted excelsheet while trying to open

Hi folks, I am trying to send the mail with spreadsheet attachment in perl.I am able to send the mail with xlsx attachment as well but not able to open the xlsx sheet.While opening the sheet I am receiving the corrupted message. Below is the code. use MIME::Lite; use Net::SMTP; ###... (1 Reply)
Discussion started by: scriptscript
1 Replies

10. Shell Programming and Scripting

Extract sentence and its details from a text file based on another file of sentences

Hi I have two text files. The first file is TEXTFILEONE.txt as given below: <Text Text_ID="10155645315851111_10155645333076543" From="460350337461111" Created="2011-03-16T17:05:37+0000" use_count="123">This is the first text</Text> <Text Text_ID="10155645315851111_10155645317023456"... (7 Replies)
Discussion started by: my_Perl
7 Replies
suspend(1)							   User Commands							suspend(1)

NAME
suspend - shell built-in function to halt the current shell SYNOPSIS
sh suspend csh suspend ksh suspend DESCRIPTION
sh Stops the execution of the current shell (but not if it is the login shell). csh Stop the shell in its tracks, much as if it had been sent a stop signal with ^Z. This is most often used to stop shells started by su. ksh Stops the execution of the current shell (but not if it is the login shell). ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ SEE ALSO
csh(1), kill(1), ksh(1), sh(1), su(1M), attributes(5) SunOS 5.11 15 Apr 1994 suspend(1)
All times are GMT -4. The time now is 08:52 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy