Hello!
I've got a loop in which I am processing a list of values gotten through a file with read command.
It seems that instead of processing the lines (values) one by one, I process them all together.
the input file is:
20
20
20
80
70
70
20
The code is: (2 Replies)
Hi,
Please could someone advise the issue i have with my awk command ?
my command is :
export NUM_SCENARIOS=`awk -F= '!/^#/ && /NUM_SCENARIOS/{print $2}' /home/environment.properties`
when I echo $NUM_SCENARIOS
this comes back with :
100 10
The issue I have is, there is... (9 Replies)
Hi folks.
I am trying to use a while loop along with awk to get the colums where 2 specific words are found.
Here is the output of the command i run where i need to pull the column numbers if specific words are found:
State Type Rebal Sector Block AU Total_MB Free_MB ... (3 Replies)
Hi
I am not able to solve this minor issue even after a lot of trial! Will be thankful if you can help me out. This is part of a awk script and the loop is self-explanatory -
num_null_key=0 #for counting the number of null keys
num_non_null_key=0 #for counting the number of non null... (2 Replies)
Hi All,
I am using the below script which has awk command, but it is not returing the expected result. can some pls help me to correct the command.
The below script sample.ksh should give the result if the value of last 4 digits in the variable NM matches with the variable value DAT. The... (7 Replies)
Greetings Experts,
I need to handle the views created over monthly retention tables
for which every new table in YYYYMMDD format, there is
equivalent view created and the older table which might be
dropped, the view over it has to be re-created over a dummy
table so that it doesn't fail.... (2 Replies)
Hi
I am trying to parse a grep output using awk. It works fine individually and not working under the loop with variable name assigned.
cat > file.txt
dict=/dictr/abcd/d1/wq:/dictr/abcd/d2/wq:/dictr/abcd/d3/wq:
sample tried code
Nos=`grep -w "dict" file.txt | awk -F"=" '{print... (10 Replies)
I am new to unix.I have a requirement to get few fields from the log file as below.
Log
app9/cc-gr_base.log.2017-07-19.gz: hostname 1500523166993 NA:NA:NA http-nio-8080-exec-56 INFO Points balance from MIS for user with userId: 19651069, first name: DEREK RICHARD and last name: BOUDREAU is... (3 Replies)
Dear all,
I would be grateful for your help with the following.
I have the following file (file.txt), which is about 10,000 lines long:
ID1 ID2 0 1 0.5 0.6
ID3 ID4 0 0 0.4 0.8
ID1 ID5 0 1 0.5 0.3
ID6 ID2 1 0 0.4 0.8
The IDs in the first two columns can occur between... (12 Replies)
Good day to all,
I'd like to ask for your advice with regards to this.
Scenario :
I have here a file named TEST.tmp wherein the value inside is below;
"ONE|TWO|FIVE|THREE|FOUR|SIX~SEVEN~EIGHT" "NINE"
But when I'm trying to use this in a simple command like;
for TESTING in $(cat... (4 Replies)
Discussion started by: asdfghjkl
4 Replies
LEARN ABOUT HPUX
annuity
annuity(3M)annuity(3M)NAME
annuity(), annuityf(), annuityl(), annuityw(), annuityq() - present value factor for annuity
SYNOPSIS DESCRIPTION
The function computes the present value factor for an annuity:
(1 - (1 + rate) ** (-periods)) / rate
is a version of it takes arguments and returns a result.
is a version of it takes arguments and returns a result.
is an version of it takes arguments and returns an result.
is equivalent to on HP-UX systems.
USAGE
To use these functions, compile either with the default option or with the and options. To use compile with the option. Make sure your
program includes Link in the math library by specifying on the compiler or linker command line.
RETURN VALUE
If periods equals zero, returns 0.0.
Else, if rate equals zero, returns periods.
Else, if either argument is a NaN, returns a NaN.
Else, if rate < -1, returns a NaN and raises the invalid exception.
Else, if rate = -1 and periods = +INFINITY, returns +INFINITY.
Else, if rate equals -1 and periods > 0, is equivalent to
Else, if rate equals -1, returns -1.
Else, if rate equals +INFINITY and periods >= 0, returns +0.0.
Else, if rate equals +INFINITY and -1 < periods < 0, returns -0.0.
Else, if rate equals +INFINITY and periods = -1, returns -1.
Else, if rate equals +INFINITY, returns -INFINITY.
Else, if periods is infinite and (rate * periods) > 0, is equivalent to
Else, if periods is infinite, returns periods.
returns a properly signed infinity in lieu of a value whose magnitude is too large, and raises the overflow and inexact exceptions.
raises the underflow and inexact exceptions whenever a result is tiny (essentially denormal or zero) and thereby suffers loss of accuracy,
and may raise those exceptions if the result is merely tiny.
ERRORS
No errors are defined.
SEE ALSO compound(3M), exp(3M), expm1(3M), pow(3M), math(5).
STANDARDS CONFORMANCE
These functions are not specified by any standard.
HP Integrity Server Only annuity(3M)