Need timestamp conversion shell script !!

Can anyone provide me with a ksh or bash script which will accept a timestamp (format is YYYY-MM-DD-HH24.Mi.Ss) and time offset (in hours). The output will be (timestamp passed - time offset passed deducted from it) in the same YYYY-MM-DD-HH24.Mi.Ss format.

Basically I am trying to convert the timestamp string (in the format as above) from GMT to EST (EST is 5 hrs behind GMT). If anyone can think of any AIX built-ins for the same, that can also help.

Thanks in advance for your help.

Have a look at the FAQ article: http://www.unix.com/answers-frequently-asked-questions/13785-yesterdays-date-date-arithmetic.html

should find what you want in there.

HTH