Search Results

Search: Posts Made By: centurion_13
3,329
Posted By centurion_13
Sorting a particular column in PERL
I have a file abc.txt which contains data in th following format

abc,23
hgfh,87
tweg,89
jdfjn,74
I want to sort on the basis of column (the second one). It should be numerical sort.
...
8,355
Posted By centurion_13
Please give how is it working ?? OFS and ORS...
Please give how is it working ??
OFS and ORS what do they signify
8,355
Posted By centurion_13
Can u please explain how used it ...Hwz it working
Can u please explain how used it ...Hwz it working
8,355
Posted By centurion_13
awk /nawk :: print the everything except the first and the last fields
format of file1 "file1.txt"

1 2 3 4
A B C
XX YY ZZ AA WWW

The output must contain except the first and last column
the output must be

2 3
B
YY ZZ AA
8,879
Posted By centurion_13
What does this arabic($1) stand for ????
What does this arabic($1) stand for ????
3,332
Posted By centurion_13
problem in nawk : case insensitive pattern matching
HI,

My file contains data something like
034500,5,B5004946544EB185,DEFAULT,0

Now i want to do a pettern match for DEFAULT and remove that particular line from file and transfer the rest...
2,628
Posted By centurion_13
See array1 2nd parameter (if spliting parameter...
See array1 2nd parameter (if spliting parameter is |_|)
Similarly array2's 1st parameter ( if splitting parameter is |_|)

If this above 2 parameters match put that particular record in array3 in...
1,256
Posted By centurion_13
nawk -F"|" 'NR==FNR{a[$1]=$0;next}a[$1]{print...
nawk -F"|" 'NR==FNR{a[$1]=$0;next}a[$1]{print $0}' a b
2,628
Posted By centurion_13
perl : merging two arrays on basis of common parameter
I have 2 arrays,

@array1 contains records in the format
1|_|X|_|ssd|_|
4|_|H|_|hbd|_|
9|_|Y|_|u8gjdfg|_|

@array2 contains records in the format
X|_|asdf|_|
Y|_|qwer|_|
A|_|9kdkf|_|
...
1,617
Posted By centurion_13
Thanks berei :b: Can u just explain each...
Thanks berei :b:

Can u just explain each parameter of your awk command.
1,617
Posted By centurion_13
nawk -- separation of records on basis of number of fields
A file file1.txt exists having records like

The delimiter being "|"

X|_|Y|_|Z|_| (number of fields 7)
A|_|B|_| (number of fields 5)...
1,205
Posted By centurion_13
How to handle exceptions in "nawk -F"
Suppose the nawk -f doesnot work due to some reasons ,in such a case how to handle the exceptions or the error messages

nawk -f "|" 'NR==FNR{a .......} ..print{ $0} file_1.txt file_2.txt >...
1,717
Posted By centurion_13
Thanks Dhiren Suppose a particular record...
Thanks Dhiren

Suppose a particular record in the file_2.txt or file_1.txt is not in the format
2|_|X|_|then how to handle such cases???

Suppose now the file_2.txt records are in the format...
1,717
Posted By centurion_13
match 2 files using nawk command
i am matching two files.
the files are in the format

file_1.txt
1|_|X|_|
2|_|W|_|
3|_|Y|_|
4|_|Z|_|
5|_|U|_|


file_2.txt
W|_|A|_|
Z|_|C|_|
V|_|B|_|
X|_|D|_|sdff|_|
Y|_|

...
Showing results 1 to 14 of 14

 
All times are GMT -4. The time now is 04:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy