This is my work related.. in development we have bash shell... below command is working fine.. but in prod environment we have korn shell and the same command is failing..
here
V_NO_of_Dec is the number of decimals that needed in output
COL_VAL_1 is input value
I want to be able to generate a random number within a korn shell script..
Preferably i would like to be able to state how many digits should be in this random number... ie 4 digits or 5 digits etc
Any ideas? (2 Replies)
I have a file like this:
Tue Apr 15 10:41:47 MDT 2008 FINAL RESULT; 6
Tue Apr 15 10:41:47 MDT 2008 FINAL RESULT; 2
Tue Apr 15 10:41:47 MDT 2008 FINAL RESULT; 5
With this command seira=`cut -f 2 -d ';' tes.txt` i take all the results (6,2,5 etc) and i store them in variable seira
When i do... (9 Replies)
I am writing a script to keep check on free disk space, and I would like to find a way to parse $LINE (see code below) into a numeric value (for free disk space percentage) and a string value (for mount point). If possible, I would like to avoid sed or any additional use of awk since I am not very... (7 Replies)
I'm writing a KSH script that will get a file on the command line (such as input.txt), and in this file there is on number per line. The program needs to take the file, read each and determine the lowest number in the file. I currently have a while loop setup that will correctly out put every... (8 Replies)
Hi everybody, I have a string stored in a variable called record:
record="SNMPv2-SMI::ent.9.9.43.1.3.9.2 = Timeticks: (177330898) 20 days, 12:35:08.98"
I want to write some regular expressions good for Korn Shell to extract the number between parenthesis, in this case 177330898, and put it in... (3 Replies)
I have a task. The scenario is like this. I have a operation program (OPR1) , whose function is to simply double the (single)value it receives as input.
I have to write a script to operate the OPR1 and save its output in a file.
Later, I have to modify the script so as to be able to operate ... (0 Replies)
hello,
i have a variable which should have following content :
var="value1"
or
var="value2"
or
var="value2:*" # example: value2:22
how can i check :
- if the content is ok (value1 / value2* )
- the two options of "value2"
when content is example "value2:22" , i want to split... (3 Replies)
Anyone ever seen this? Someone mentioned this the other day....
If you do, for instance, in korn shell, echo $(5.2+2.5), it gives the result of 6 regardless.
Can't remember why but it was the limitation of the korn shell. (5 Replies)
Discussion started by: psychocandy
5 Replies
LEARN ABOUT HPUX
news
news(1) General Commands Manual news(1)NAME
news - print news items
SYNOPSIS
[items]
DESCRIPTION
is used to keep the user informed of current events. By convention, these events are described by files in the directory
When invoked without arguments, prints the contents of all current files in most recent first, with each preceded by an appropriate header.
stores the ``currency'' time as the modification date of a file named in the user's home directory (the identity of this directory is
determined by the environment variable only files more recent than this currency time are considered ``current.''
Options
recognizes the following options:
Print all items, regardless of currency.
The stored time is not changed.
Report the names of the current items without printing their contents,
and without changing the stored time.
Report how many current items exist without printing
their names or contents, and without changing the stored time. It is useful to include such an invocation of news in
one's file, or in the system's
All other arguments are assumed to be specific news items that are to be printed.
If an interrupt is typed during the printing of a news item, printing stops and the next item is started. Another interrupt within one
second of the first causes the program to terminate.
EXTERNAL INFLUENCES
International Code Set Support
Single- and multi-byte character code sets are supported.
FILES SEE ALSO mail(1), profile(4), environ(5).
STANDARDS CONFORMANCE news(1)