10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi Guys,
I have an issue with awk and variables. I have trawled the internet and forums but can't seem to get the exactt syntax I need.
I have tried using awk -v and all sorts of variations but I have hit a brick wall. I have spent a full day on this and am just going round in circles.
... (3 Replies)
Discussion started by: gazza-o
3 Replies
2. Shell Programming and Scripting
Hi There,
I am writing a ksh script which assigns variable values from file "A" and passes that variables to file "B". While passing the parameters an additional "$" sign is being assigned to awk -v option.
Could any one help me with this please.
#!/bin/ksh
head -1... (3 Replies)
Discussion started by: Jeevanm
3 Replies
3. UNIX for Advanced & Expert Users
Hi,
I am setting up SUID permissions on a binary.
It gets set for most of the users, however, 1 in 10 users is unable to set these.
For those who works:
> chmod 6555 Test
> ls -l Test
-r-sr-sr-x 1 A B 5524 Nov 15 14:53 Test
For those where it doesn't work:
> chmod 6555 Test... (14 Replies)
Discussion started by: vibhor_agarwali
14 Replies
4. Shell Programming and Scripting
Hi,
I'm trying to execute a job on the last day of every month, for which i'm using the following code in my Korn shell script :
if ];
then
echo allowed only on last day of month. Today is `date +%d` >t.stm
echo Tomorrow is `date +%d -d tomorrow` >s.stm
exit 0
fi
...
....... (7 Replies)
Discussion started by: devilsadvocate
7 Replies
5. Shell Programming and Scripting
Hi all,
I have a KSH script which is kicking off an sql scripts as follows:
/usr/local/installs/instantclient_10_2/sqlplus -s username/password @$sql_path/sql_query.sql > $tmp_path/sql_query_results
The problem I have is that sometimes the 10g Oracle Database spits out an error saying... (4 Replies)
Discussion started by: Donkey25
4 Replies
6. Shell Programming and Scripting
How do i get the value of the variable from the called script(script2) to the calling script(script1) in ksh ?
I've given portion of the script here to explain the problem.
Portion of Script 1
=============
-----
-----
tmp=`a.ksh p1 p2 p3`
if then
# error processing
fi
-----... (10 Replies)
Discussion started by: rajarkumar
10 Replies
7. Shell Programming and Scripting
I have a file called merge2.t:
Hi
Hello how are you.
</Endtag> <New> I am fine.</New>
This is a test.
freelong
how
Here is the SED:
sed -n ' /<\/Endtag>/ !{
H
}
/<\/Endtag>/ {
x
p
} (4 Replies)
Discussion started by: freelong
4 Replies
8. HP-UX
Hello all,
Normally I'm pretty comfortable with crontab, changing and updating (done it many-a-time).
But in the last two days I've been pulling my hair out over the following...
Details of OS:
HP-UX mdirect B.11.23 U ia64 2587410573 unlimited-user license
Issue:
Execute a script (very... (3 Replies)
Discussion started by: Cameron
3 Replies
9. UNIX for Advanced & Expert Users
Hi All,
a bit of a weird one here. I'm trying to pass a variable into an awk command, and I keep getting an error.
I have the line
nawk -F"," -v red=$random_variable '{print $red}' $w_dir/$file_name > $w_dir/${column_name}
that keeps failing with the error
nawk: can't open file {print... (17 Replies)
Discussion started by: Khoomfire
17 Replies
10. Shell Programming and Scripting
I have a ksh script that connects to sqlplus and dumps the query results into a file. The script works file when I run it from the command line, however, when I call it from PHP using system(), exec(), or shell_exec() commands, the script doesn't seem to run the query. It will create the text file... (7 Replies)
Discussion started by: j2owilson
7 Replies