10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I want to run sql query in shell script and output data save as delimited text (delimited text would be comma)
Code:
SPOOL_FILE=/pgedw/dan.txt
SQL=/pgedw/dan.sql
sqlplus -s username/password@myhost:port/servicename <<EOF
set head on
set COLSEP ,
set linesize 32767
SET TRIMSPOOL ON
SET... (8 Replies)
Discussion started by: Jaganjag
8 Replies
2. UNIX for Dummies Questions & Answers
If I have a A.log
1 Air Flow Monitor : 34.070 Degrees C
2 Air Flow Monitor : 41.730 Degrees C
3 Air Flow Monitor : 35.340 Degrees C
4 Air Flow Monitor : 33.370 Degrees C
5 Air Flow Monitor : 36.770 Degrees C
6 Air Flow Monitor : 45.910 Degrees C
7 Air Flow Monitor ... (1 Reply)
Discussion started by: sabercats
1 Replies
3. UNIX for Advanced & Expert Users
My requirement is to read a column data from a file & save it in a variable for each row & process it. I am using the below code-
Leadlines="$TGTFILE/Error.txt">>$log_file
while read line
do
id = ` echo $line | cut -d "," -f1 `
email = ` echo $line | cut -d "," -f2 `
-----------
done
My... (2 Replies)
Discussion started by: saga20
2 Replies
4. UNIX for Dummies Questions & Answers
Dear every one,
I am working with the data of my lab program and I have to do many times by the same list of some commands (grep, then save to file, then use awk to delete odd lines, save to file, use awk to delete even lines, save to file...).
Is there any way to save a list of command which I... (4 Replies)
Discussion started by: phamnu
4 Replies
5. Shell Programming and Scripting
Hi all;
I have the following code which gives me kind of what I need:
#!/usr/bin/perl
use Fcntl ':mode';
#
if ($ARGV ne "") {
$filename = $ARGV;
} else {
print "Please specify a file!\n";
exit;
}
#
if... (2 Replies)
Discussion started by: gvolpini
2 Replies
6. Shell Programming and Scripting
Dear All,
I am writing a script and kind of stuck in a small thing. Cannot figure it out. so please help
I am logged in as root user. I want to switch user to "user1" inside the script and execute a specific command lets say "pwd" and come back where i started.
I know how to switch user,... (16 Replies)
Discussion started by: suhail.sadaqat
16 Replies
7. UNIX Desktop Questions & Answers
Hi
I am new to linux, when I typed "vi FILE1" I was able to open VI editor. I added some data and I want to save the file and I tried :w but it threw me an error.
"file1" E212: Can't open file for writing
Press ENTER or type command to continue
why I am not able to save it?
I read it... (16 Replies)
Discussion started by: chinnanji
16 Replies
8. Homework & Coursework Questions
Im trying to come up with a simple shell script to display info about the current user.`pwd`; `date` ; `who am i`
I want to give the option to save all the data thats display by the commands to a log file. With a timestamp as the name of the file
This is where im stuck
echo "Would you like to... (3 Replies)
Discussion started by: eddieq20
3 Replies
9. Linux
I have installed fedora 9 and trying to run .pl (perl files) from browser.
I have below RPM installed:
----------------------------------
httpd-2.2.8-3.i386
mod_perl-2.0.3-21.i386
$cat /etc/httpd/conf.d/perl.conf
LoadModule perl_module modules/mod_perl.so
Alias /perl /var/www/perl... (4 Replies)
Discussion started by: sriram003
4 Replies
10. Filesystems, Disks and Memory
Hello,
Our RAID and server recently crashed and we are trying to recover our data. The problem appears to be that the Veritas File System/Logical Volume Manger became corrupt on our RAID. We are down to our last option, which is to run some Veritas commands that "may" result in data loss.
... (1 Reply)
Discussion started by: stringman
1 Replies