Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Click here to start participating now! Also, check out the New User Guide.
Assign Date to a Var
Name: Nish Date: September 30, 2002 at 00:26:04 Pacific OS: Solaris 7 CPU/Ram: 256
Comment:
Dear All, My OS : Solaris and Shell is ksh. I have a requirement to assign date to a variable. I tried following and failed.
myvar=date '+ %y%m%d_%h'
After that I need to do an awk fo all the files containing the same date and hour. (File name consists of date and hour) eg. Myfile_NAME_020930_1325.0010 Therefore I need to awk all files that created this hour. Appreciate your Help.
Summary: Hi All, I need to do develop a script in ksh to do the following. Go to a particular directory (say /opt/alpha) List files (using ls -ralt) List the last updated file (ls -ralt|tail -1) Assign the upd...
Summary: All, I have a sequence of files that are generated from several hosts (ABC, DEF ... XYZ). File name has following format. ABC_030114_0010.0000 ABC_030114_0113.0001 .... ... ABC_030114_2358.0138 These ...
Summary: I need to calculate the Yesterday's date and received a good code from Unix forum. I need to assign the yesterdays Date (MONTH and DATE eg. 1229 for Dec 29)to a Variable ,say myvar. $myvar can be used...