dp(8mh)dp(8mh)Name
dp - parse dates RFC 822-style
Syntax
/usr/lib/mh/dp [ -form file ] [ -format string ] [ -help ] [ -width columns ] dates
Description
The command parses dates according to the ARPA Internet standard. It also understands many non-standard formats, such as those produced by
TOPS-20 sites and some UNIX sites using It is useful for seeing how MH will interpret a date.
The program treats each argument as a single date, and prints the date out in the official RFC 822 format. Hence, it is usually best to
enclose each argument in double quotes (") for the shell.
Options-form file
Overrides the default output format of The output is formatted according to the instructions in the specified file. This must be
a format file; see
-format string
Overrides the default output format of The output is formatted according to the instructions in the specified string. This must
be a format string; see
The argument to the -format option must be interpreted as a single token by the shell that invokes Therefore, you should usually
place the argument to this option inside double quotes (").
-help Prints a list of the valid options to this command.
-width columns
Specifies the width of the screen in columns.
The defaults for this command are as follows:
-width defaults to the width of the terminal
Examples
This is the default format string used by
%<(nodate{text})error: %{text}%|%(pretty{text})%>
When an error is detected, this prints error: and the date that is in error. Otherwise, it outputs the proper RFC 822 format of the date.
Files
User profile.
See Alsoap(8mh)
Standard for the Format of ARPA Internet Text Messages (RFC 822)
dp(8mh)
Check Out this Related Man Page
dp(8) System Manager's Manual dp(8)NAME
dp - parse dates RFC 822-style
SYNOPSIS
/usr/lib/mh/dp [-form file] [-format string] [-help] [-width columns] dates
OPTIONS
Overrides the default output format of dp. The output is formatted according to the instructions in the specified file. This must be a
format file; see mh-format(4). Overrides the default output format of dp. The output is formatted according to the instructions in the
specified string. This must be a format string; see mh-format(4).
The argument to the -format option must be interpreted as a single token by the shell that invokes dp. Therefore, you should usually
place the argument to this option inside double quotes ("). Prints a list of the valid options to this command. Specifies the
width of the screen in columns.
The defaults for this command are as follows:
-width defaults to the width of the terminal
DESCRIPTION
The dp command parses dates according to the ARPA Internet standard. It also understands many non-standard formats, such as those produced
by TOPS-20 sites and some UNIX sites using ctime(3). It is useful for seeing how MH will interpret a date.
The dp program treats each argument as a single date, and prints the date out in the official RFC 822 format. Hence, it is usually best to
enclose each argument in double quotes (") for the shell.
EXAMPLES
This is the default format string used by dp:
%<(nodate{text})error: %{text}%|%(pretty{text})%>
When an error is detected, this prints error: and the date that is in error. Otherwise, it outputs the proper RFC 822 format of the date.
FILES
User profile.
SEE ALSO
Commands: ap(8)
Standard for the Format of ARPA Internet Text Messages (RFC 822)
dp(8)
The date outputs the difference in this format YYYYMD. I think it would be better to have the output as YYYYMMDD. Im having problem processing the format.
Thank you (9 Replies)
Hi, I have a script that outputs a file that contains the dates from the previous month, which is then used by our application to run processes on each date contained in the file. My problem is is that my script created a blank line at the bottom of the file which causes issues for our... (14 Replies)
I have following script..
which print date on screen continuously..
i start it on command line..
once its started it will go on...
IS THERE ANY WAY TO SEND TO TO BACKGROUND ONCE ITS STARTED???
thanks,
vidya... (10 Replies)
Hi,
I have some data in text file as
123
45
34
5
66
I want to create a file as in table format as below:
table1 123 45 5
tab2 66 34
tabllllll 123 23 (19 Replies)
I need to put the output of the ps -ef command into a string.
echo'n that string must display the output similiar to how we see the output of ps -ef in commandline.
This is the string
message="this is the output of ps command\n\n
`ps -ef`\n\n
Output Complete"
when I echo $message the... (11 Replies)
Hi,
I run a script which outputs various records, anyway one of the columns contains the date in the format DDMMYYYY, I would like to make this DDMMYY.
Is there an easy way to do this, (11 Replies)
Hi,
I have a fixed width text file without any header row. One of the columns contains a date in YYYYMMDD format.
If the original file contains 3 dates, I want my shell script to split the file into 3 small files with data for each date.
I am a newbie and need help doing this. (14 Replies)
hi all, im having problems. I need to change all number 10 in a text file to word form, or in short from 10->ten. the thing is number 10 including in dates such as 10/22/1997 or 03-10-2011 should not be changed. im having some trouble because the file contains numbers like "price range from... (11 Replies)
I am trying to selectively display several columns from a db2 query, which gives me a fixed-width output (partial output listed here):
--------- -------------------------- ------------ ------
000 0000000000198012 702 29
000 0000000000198013 ... (9 Replies)
Hi,
I have one .csv file. I have 2 date columns present in file, column 2 and column 3.
I need to calculate how many days exist between 2 dates.
I am trying to subtract date column 2 from date column 3.
Eg: my file look likes
s.no, Start_date,End_Date
1, 7/29/2012,10/27/2012
2,... (9 Replies)
Hello All,
I have a requirement where i need to get the EXTRACT_DATE from a file and check if the date is of valid format or not and then mail it if it is not valid. Appreciate if you can help me with this.
I did the following so far.
awk '{for(i=1;i++<=NF;)if($i~/^EXTRACT_DATE/) print $i}'... (11 Replies)
Dear all,
I am trying to sort a text file based on column 3, 10, 11 and 12. But certain column are blank for some lines. Column 3 has to be in ascending order after sorting.
Part of my input file is as follows:
CN727990 1 A01 4703 5083 73.28 - A_scaffold000011 4365605 4365985 73.28 +... (10 Replies)
Hello to all,
I'm trying to match only fields surrounded by double quotes that have one or more commas inside.
The text is like this
"one, t2o",334,"tst,982-0",881,"kmk 9-l","kkd, 115-001, jj-3",5
The matches should be
"one, t2o"
"tst,982-0"
"kkd, 115-001, jj-3"
I'm trying with... (11 Replies)
Hi Team,
I need to connect to a prod server and need to get the files which falls between two dates. I should not create ant files on that machine.
I am using korn shell.
Your help is very much appreciated.
Vinay (13 Replies)
Please use code tags
Hi,
I have input data is below format and n of column in the multiple flat files. the string data has any double quotes(") values replaced to double double quotes for all the columns{"").
Also, my input flat file each column string data has carriage of new line too.... (14 Replies)