10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Would like to compare 2 XML Strings which has certain known fields changed. For example, Date field will always have differences. When comparing both strings, skip/mask all the occurring Date Field's `DtField1` and `DtField2`
Note: these are not formatted xml format.
File1:
... (1 Reply)
Discussion started by: Sajjadmehdi
1 Replies
2. Shell Programming and Scripting
Hi, I'm trying to use awk arrays to compare values across two files based on multiple columns. I've attempted to load file 2 into an array and compare with values in file 1, but success has been absent. If anyone has any suggestions (and I'm not even sure if my script so far is on the right lines)... (4 Replies)
Discussion started by: hubleo
4 Replies
3. Shell Programming and Scripting
I'm trying to compare 2 array and print the difference at a 3rd file. However how am i going to compare this 2 arrays by ignoring certain patterns:
For example:
1st array contains:
ctahci
cptcsa0
ctsata:25:seed
cptcsa1:50:seed
ctsata_1:25:seed
2nd array contains:
cptcsa0
ctsata... (0 Replies)
Discussion started by: hongping
0 Replies
4. Shell Programming and Scripting
I have the following code and for some reason when I call the program using
/home/tcdata/tatsh/trunk/hstmy/bin/bash/raytrac.bash --cmod=jcdint.cmod
I get
hasArgument =
hasArgument = true
Somehow the array element is returning even though I have not chosen the option.
... (41 Replies)
Discussion started by: kristinu
41 Replies
5. UNIX for Dummies Questions & Answers
Problem
Part 1.
Gather data from linux server and output to a file named data_DDMMYY
Output file must contain the file name and size
Part 2.
Compare todays data_DDMMYY to yesterdays data_DDMMYY and output results to a file named difference_DDMMYY
Output file must show the difference in... (3 Replies)
Discussion started by: Aussiemick
3 Replies
6. Shell Programming and Scripting
Hey all,
This is my first post, and I am relatively new to linux/unix scripts. I am writing a bash script in which I am trying to extract one line from another file and parse specific words from the line into an array. So for example, I have a file called SortScans in which the first 5 lines... (9 Replies)
Discussion started by: camocazi
9 Replies
7. UNIX for Dummies Questions & Answers
Hi There,
Code:
Number=10
i=1
while
do
echo "$i"
Check=`find $viewing -name $File_Pattern -type f -Print`
i=`expr ${i} + 1`
done
Unable to store the values in variable 'Check', when i display i am getting Check nothing... (1 Reply)
Discussion started by: Naveen_5960
1 Replies
8. Shell Programming and Scripting
Hi there, i have been trying different methods and i wonder if somebody could explain to me how i would perform a comparison on two arrays for example
my @array1 = ("gary" ,"peter", "paul");
my @array2 = ("gary" ,"peter", "joe");
I have two arrays above, and i want to something like this... (5 Replies)
Discussion started by: hcclnoodles
5 Replies
9. Shell Programming and Scripting
Hi all,
I am trying to compare two arrays in perl using the following code.
foreach $item (@arrayA){
push(@arrayC, $item) unless grep(/$item/, @arrayB); ... (1 Reply)
Discussion started by: chriss_58
1 Replies
10. Shell Programming and Scripting
Is there anyway that I can compare two Arrays to see if any new strings have been added in them? eg:
Array 1: Joe Bob Jane
Array 2: Joe Bob Jane Greg
It would then output a new array with the changes:
Array 3: Greg
I'm not very good at shell scripting, and my google and forum searches... (4 Replies)
Discussion started by: blckleprd
4 Replies