hi
the code i ve written is as follows:
command="egrep ',100,|,200,' | wc -l"
count =`cat trial.txt | $command`
echo "$count"
the contents of
trial.txt is :
000,100,200,300,
001,200,100,201,
002,200,100,400,
i need to get the count using the command stored in a variable and using... (2 Replies)
Hi,
I want to write a perl script, which will increment number stored in file. I want to do this without any file handles. I think we have to use some UNIX commands. I am not sure how to do this with file handles.
Thanks, (1 Reply)
Hi all,
I have a variable say var1 (output from somewhere, which I can't change)which store something like this:
echo $var1
name=fred
age=25
address="123 abc"
password=pass1234
how can I make the variable $name, $age, $address and $password contain the info?
I mean do this in a... (1 Reply)
can anyone please help me with this:
i have written a shell script and a stored procedure which has one OUT parameter. now i want to use that out parameter as an input to the unix script but i am getting an error as variable not found. below are the unix scripts and stored procedure...
... (4 Replies)
I need help to store the value returned from the function to one variable and then use that variable.
PREVIOUS_DATE_FUNCTION()
{
date '+%m %d %Y' |
{
read MONTH DAY YEAR
DAY=`expr "$DAY" - 1`
case "$DAY" in
0)
MONTH=`expr "$MONTH" - 1`
case... (1 Reply)
hey, i have stored values of query like this
val_2=$( sqlplus -s rte/rted1@rel75d1 << EOF
set heading off
select source_id from cvt_istats where istat_id > $val_1;
exit
EOF
)
echo $val_2
now , val_2 has five values displayed like this
1
2
3
4
5
what i have to do is to check the... (1 Reply)
I'm trying to get a list of all users on the system, store the list in a variable, then find all the files of a certain extension owned by each of the users.
The command I use to get the list is
getent passwd | cut -d: -f1 | sortand this works just fine. However, if I try to store it in a... (1 Reply)
I am trying to store a string value to a temporary variable within my script. When I run the command manually it returns the expected value, but from the script an additional "\r" is at the end.
tCurrentStatus=`cat ${tPC_status} | grep 'Current status' | awk '{print $NF}'`
output:
cat... (1 Reply)
Hi All,
I have below variable,
xyz=\$AI_XFR
Now, if you will run the below command
=> echo $xyz
$AI_XFR
It is returning hardcoded string value.
Whereas in environment, there is value in it. Like below:
=> echo $AI_XFR
/home/aditya/sandbox/xfr/
I need to resolve this... (4 Replies)
I'm writing a shell script in AIX and using ksh.
I have a scenario where I have a variable A which stores $B.
so when i echo "$A" it prints $B
But I wish to print value stored in var b ie. \a\dir\res\
I wish to store \a\dir\res\ in a third variable C.
later I want to cd into that path :... (1 Reply)
Discussion started by: simpltyansh
1 Replies
LEARN ABOUT DEBIAN
ucf.conf
UCF.CONF(5) Debian GNU/Linux manual UCF.CONF(5)NAME
ucf.conf - site-wide configuration file for ucf
SYNOPSIS
/etc/ucf.conf
DESCRIPTION
The file /etc/ucf.conf is actually a Bourne Shell snippet included during the package build process, and hence you may put any shell direc-
tive in that file (just make very sure you know what you are doing).
All the variables have reasonable default values, and some may be overridden on a per run or a per individual basis by using environment
variables, and all configurable variables can be overridden by options to the scripts themselves.
The value of a variable can be set so:
a) Defaults exist in the rules file. These are the values used if no customization is done.
b) Some variables can be set in the config file /etc/ucf.conf. These values override the defaults.
c) Some variables can also be set by setting a corresponding environment variable. These values override the config file and the defaults.
d) Using script command line options. All configurable variables may be set by this method, and will override the other methods above.
Configuration File options
At the moment, the user modifiable variables supported are:
DEBUG Debugging information: The default value is 0 (no debugging information is printed). To enable debugging output, set the
value to 1.
VERBOSE Verbosity: The default value is 0 (quiet). To change the default behavior, set the value to 1.
conf_force_conffold
Force the installed file to be retained. The default is to have this variable unset, which makes the script ask in case
of doubt. This can be overridden by the environment variable UCF_FORCE_CONFFOLD
conf_force_conffnew
Force the installed file to be overridden. The default is to have this variable unset, which makes the script ask in case
of doubt. This can be overridden by the environment variable UCF_FORCE_CONFFNEW
conf_source_dir This is the directory where the historical md5sums for a file are looked for. Specifically, the historical md5sums are
looked for in either the file ${filename}.md5sum, or the subdirectory ${filename}.md5sum.d/
conf_old_mdsum_file
Force the historical md5sums to be read from this file, rather than defaulting to living in the source directory. Set-
ting this option overrides settings in the environment variable UCF_OLD_MDSUM_FILE
Files
System-wide defaults are placed in /etc/ucf.conf,
SEE ALSO ucf(1),
BUGS
There are no bugs. Any resemblance thereof is delirium. Really.
AUTHOR
This manual page was written by Manoj Srivastava <srivasta@debian.org>, for the Debian GNU/Linux system.
Debian Feb 12 2002 UCF.CONF(5)