Hi All
I want to delete trailing zeros from varible.
ex:
if variable value is 1234.567000 result as 1234.567
if variable has 1234.0000 result as 1234
if variable as abcd.fgh result as abcd.fgh
Can somone give me a solution using awk? (16 Replies)
Hi All,
I would like to trim the following input.
My condition is as long as there's a zero on the left of the number, remove the zeros. Can anybody help me by using sed or awk ?
Eg:
0011 => change to => 11
0333 => change to => 333
4444 => No change => 4444 (13 Replies)
We have a large number of oracle database related scripts that utilize the environment variables $ORACLE_SID and $DBNAME. In a single instance database the $ORACLE_SID is the same as the database name $DBNAME. So we have simply set DBNAME = $ORACLE_SID. However, now that we are clustering with RAC,... (5 Replies)
So, I can't figure out how to do a previous question with printf, so I'm taking a different approach. Suppose I have a set of numbers:
1200,135.000000,12.30100,3212.3200,1.759403,,1230,101.101010,100.000000
I want to remove all trailing zeroes after the decimal, and, if it ends up orphaned,... (8 Replies)
Hi I have a simple request but can't find the answer. I want to remove trailing zeros, and in some cases the fullstops, from the input data. Example of input file:
FR002_15.000_20.000
SD475_5.000_10.500
FG5647_12.250_15.500
BH2463_30.555_32.000
Desired output file would be:
... (10 Replies)
Hi all,
I haven't needed to do any shell based editing for nearly 20 years, and no amount of searching around has found me a solution to this very simple problem :-(
I have a csv file.
Some lines have three commas at the end. This means the invoice hasn't been paid.
I'd like to use sed / grep... (4 Replies)
I have been given a shell script that I need to amend. To do the following
extract the filename from the flag file by removing the .flag extension.
# Local variables
# Find if the flag files exists
MASK=coda_mil2*.flag
# Are there any files?
bookmark="40"
fileFound=0
ls -1... (3 Replies)
I have been trying to remove empty lines and lines just filled with spaces. I have used the following command which does work.
sed -i "/^\s*$/d"
Except it leaves one single trailing line at the very end of the file. For the life of me I cant figure out why I cant remove that last trailing... (2 Replies)
Hi,
I am trying to remove trailing zeros from numbers in a csv file.
CSV Input : 0.5000,abc,2.00,2.400,285.850,285a.850,205.180800,mno000,a0b0,2.860
Expected Output :
.5,abc,2,2.4,285.85,285a.850,205.1808,mno000,a0b0,2.86
Can you please help.
Thanks. (11 Replies)
Discussion started by: manubatham20
11 Replies
LEARN ABOUT ULTRIX
anno
anno(1mh)anno(1mh)Name
anno - annotate messages
Syntax
anno [ +folder ] [ msgs ] [ -component field ] [ -help ] [ -[no]inplace ] [ -text body ]
Description
The command annotates a message by adding one or more header fields to the message.
The command allows you to choose the name of the header field which you add. It records the date at which the message is annotated, and
allows you to add an additional field containing text, if you wish.
You can use with and to keep track of how you have distributed, forwarded, or replied to messages.
By default, annotates the current message in the current folder. You can select another message by using the msg and +folder arguments.
You can also annotate more than one message, or a range of messages.
Options-component field
Specifies the name of the header field which adds. It should be a valid RFC 822-style message field name, which means that it
should consist of alphanumeric characters or dashes only. If you do not supply this option, will prompt you for the field name.
-help Prints a list of the valid options to this command.
-inplace
-noinplace
The -inplace switch causes annotation to be done in place in order to preserve links to the annotated message.
-text body
Allows you to add a header field containing text to the message. The command will create a second header field on the message,
containing the text that you specify. If the text contains a space, you must enclose the text in double quotes ("). If you do
not supply this option, adds only one field, which contains the date of the annotation.
The default settings for this command are:
+folder defaults to the current folder
msgs defaults to the current message
-noinplace
Examples
This example annotates message number 1 in the folder The -component option specifies the name of the header field:
% anno 1 +test -component Forwarded
The following field is added to the message header:
Forwarded: Tue, 08 Jan 91 16:10:06 +0000
The next example shows how to use the -text option to add an additional field:
% anno -component Forwarded -text "to David - as requested"
The following lines are added to the message header:
Forwarded: Tue, 08 Jan 91 16:13:27 +0000
Forwarded: to David - as requested
The final example shows how prompts for the name of the header field, if the -component option is not supplied:
% anno
Enter component name: forwarded
The following line is added to the message:
forwarded: Tue, 08 Jan 91 16:21:58 +0000
Profile Components
Path: To determine your Mail directory
Files
The user profile.
See Alsodist(1mh), forw(1mh), repl(1mh)anno(1mh)