![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| 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 |
| Is there a better way I could have run this loop. (For loop with two variables) | DeCoTwc | Shell Programming and Scripting | 2 | 03-27-2009 02:07 AM |
| while loop inside while loop | panknil | Shell Programming and Scripting | 0 | 01-07-2008 12:49 PM |
| for loop help | smtpgeek | Shell Programming and Scripting | 12 | 11-09-2005 08:04 PM |
| while loop | whited05 | Shell Programming and Scripting | 2 | 11-03-2005 12:27 PM |
| how to get the similar function in while loop or for loop | trynew | Shell Programming and Scripting | 3 | 06-17-2002 12:09 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
loop
I am posting my last problem more clearly here
I have 5 files file.20090502.txt, file.20090501.txt, file.20090430.txt, file.20090429.txt, file.20090428.txt, I have three variables with date1, date2 and [date1-date2] . date1=20090502 [stringformat] date2=20090429 [string format] date1-date2=3 Now the requirement is I have to pull 3 files file.20090502.txt, file.20090501.txt, file.20090430.txt Condition is: while date1-date2=3; then today is 20090502 and so pull file.20090502.txt, while date1-date2=2; then today is 20090501 and so pull file.20090501.txt while date1-date2=1; then today is 20090430 and so pull file.20090430.txt while date1-date2=1; exit Can somebody plz help me? Thanks in advance |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|