The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Persian Calendar 2.2 (Default branch) iBot Software Releases - RSS News 0 06-02-2008 11:30 AM
Bika 1.0 (Calendar branch) iBot Software Releases - RSS News 0 05-27-2008 10:30 PM
k5n Desktop Calendar 0.9.7 (Default branch) iBot Software Releases - RSS News 0 01-21-2008 09:00 PM
How to make a daily calendar with OOo iBot UNIX and Linux RSS News 0 12-07-2007 12:20 PM
Calendar date to Julian and Back BCarlson Shell Programming and Scripting 4 05-14-2005 06:18 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 04-17-2007
autouser123 autouser123 is offline
Registered User
  
 

Join Date: Mar 2007
Posts: 6
Derive date from a calendar

I'm using AutoSys as scheduler for my application.

I maintain a calendar in AutoSys which specifies when a job should run. A unix shell scripts runs on the days spceified by calendar and processes incoming files.
These incoming files contain dates embedded in the filenames.

My job needs to pick up the files whose date is same as the job run date.(Please note that run date may not be current date on few occasions and hence I cannot go by this method)

So, I want to read the calendar for the date and then look up for the filename containing that date.

Can anyone suggest if this is possible?


Thanks
  #2 (permalink)  
Old 04-17-2007
ennstate ennstate is offline
Registered User
  
 

Join Date: Mar 2007
Location: Chennai
Posts: 222
You wanted the file name which has got the date as that of the current date/job run date.Am i right?

What is the format of the embedded date in the file name? Can we not get the current date and list all files that has the current date in it using find commands name pattern expression?

Thanks
Nagarajan Ganesan.
  #3 (permalink)  
Old 04-17-2007
autouser123 autouser123 is offline
Registered User
  
 

Join Date: Mar 2007
Posts: 6
Yes, In normal scenarios, my job run date is same as current date.
In such cases, I'm looking up for files which have current date in file name.

But, there are certain situations where my job preprocessing takes longer time and eventually current date is different than the job start date (run date).

If I go with current date, I may end up picking up wrong files.

That is the reason I was looking if any common possible appraoch is present.

I understand that I can look for files as soon as the job starts so that current date remains same. But, wanted to know if there is any way to query calendar and get date.
Closed Thread

Bookmarks

Tags
autosys

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 05:43 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0