10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
My program run without error. The problem I am having.
The program isn't outputting field values with the column headers to file.txt.
Each of the column headers in file.txt has no data.
MEMSIZE SECOND SASFoundation Filename
The output results in file.txt should show:
... (1 Reply)
Discussion started by: dellanicholson
1 Replies
2. UNIX for Dummies Questions & Answers
I have several problems with my problems: I hope you can help me.
1) the If else statement I am getting an error message. My syntax must be incorrect because the entire statement is throwing an error.
For example in filew.log if these items don't exist Memsize, SASFoundation and also if... (0 Replies)
Discussion started by: dellanicholson
0 Replies
3. Shell Programming and Scripting
Hello everybody,
I am trying to assign multiple values from text into a single variable in bash.
Source TXT:
1 THIS IS THE ENTITY1 NAME1
2 THIS IS THE ENTITY2 NAME2
3 THIS IS THE ENTITY3 NAME3
while read id entity name
do
printf "$id" "$entity" "$name"
done <... (2 Replies)
Discussion started by: mrcrowley
2 Replies
4. Shell Programming and Scripting
I have a file containing multiple values, some of them are pipe separated which are to be read as separate values and some of them are single value all are these need to store in variables.
I need to read this file which is an input to my script
Config.txt
file name, first path, second... (7 Replies)
Discussion started by: ketanraut
7 Replies
5. Shell Programming and Scripting
Hi,
I have a variable which stores file names as a result of find command. I need to delete all these files one by one, i.e. by a loop. Can anyone tell me how can it be done?
The variable f2d has the file names like these
abc.txt
bcd.txt
fff.txt
gef.txt
Now I have used a loop as... (12 Replies)
Discussion started by: jhilmil
12 Replies
6. Shell Programming and Scripting
I am using a for loop to copy files from say DIR1 and DIR2 to DIR3.I have to check whether files are copied from DIR1 and DIR2 and print the respective message.
@path=("$DIR1","$DIR2");
foreach (@path) {
$rc=system("cp $_/*xml $DIR3");
if ($rc == 0)
{
print "Files were copied... (1 Reply)
Discussion started by: liyakathali
1 Replies
7. UNIX for Dummies Questions & Answers
Hi,
when I enter 'ps -ef| grep process_name'/'psu | grep process_name', i am getting multiple number of lines output( i mean multiple no of processes).how can i store it one by one and echo it in the same way(one by one).
part of script is
var1=$(remsh hostname -l username ps -ef|grep... (2 Replies)
Discussion started by: jeanzibbin
2 Replies
8. Programming
Hi,
I'm trying to set two OID's in the same PDU (so both OIDs and values are sent in the same packet) at present I am only able to send one at a time which does not trigger the hardware response as the two specific OID's need to be set simultaneously in order to work.
I'm using perl along... (0 Replies)
Discussion started by: MCLASS
0 Replies
9. Shell Programming and Scripting
Could any one tell me how to read and match multiple lines in perl? Did this code below still work in this situation?
while (<FILE>) {
if (/ /) {
}
}
Thanks a lot! (5 Replies)
Discussion started by: zx1106
5 Replies
10. Shell Programming and Scripting
Hi,
I need to generate a test data file by reading inputs from multiple files.
A sample pseudo code for this program to read from three files and write to a output file would be like:
open(OUTPUTFILE, "data");
open(INFILE1, "data1");
open(INFILE2, "data2");
open(INFILE3, "data3");
... (1 Reply)
Discussion started by: jyotipg
1 Replies