![]() |
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 |
| Help, I need to get the last date of previous month | sirrtuan | Shell Programming and Scripting | 11 | 10-14-2008 05:59 AM |
| Get date one month from today | frustrated1 | Shell Programming and Scripting | 5 | 08-15-2008 08:01 AM |
| yesterday date month/date | skully | Shell Programming and Scripting | 5 | 06-24-2008 05:51 AM |
| last month end date | vanathi | UNIX for Advanced & Expert Users | 7 | 03-21-2008 04:17 PM |
| how to get month last date in unix | rajan_ka1 | Shell Programming and Scripting | 12 | 10-04-2005 07:20 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Substract date (month) Problem
#!/bin/ksh
month=`date | cut -c5-8` year=`date | cut -c24-28` echo "$month" echo "$year" --- This gives me output as Feb and 2009 but now I want to substract the 1 month from the current script and want output as Jan 2009. Please note I have searched a lot on forum and found option -v with date but it doesn't work wd on my mc. Please help...!!! |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|