2012年4月12日星期四

How to Perform Date Calculation in AIX

How to Perform Date Calculation in AIX

1. Create a unix script with the following content :
#!/bin/sh
#

date
date '+%m%d%Y'
TZ=HKT+40
date
date '+%m%d%Y'

2. Run the script and you should get back the following result ::

Sat Jan 2 12:42:36 HKT 2010
01022010
Fri Jan 1 12:42:36 HKT 2010
01012010

Remaks :

24-hours before => TZ=HKT+16
48-hours before => TZ=HKT+40

沒有留言: