10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
I am using DB2 v9 and trying to get country values in comma seperated format using below query
SELECT distinct LISTAGG(COUNTRIES, ',') WITHIN GROUP(ORDER BY EMPLOYEE)
FROM LOCATION ;
Output Achieved
MEXICO,UNITED STATES,INDIA,JAPAN,UNITED KINGDOM,MEXICO,UNITED STATES
The table... (4 Replies)
Discussion started by: Perlbaby
4 Replies
2. Shell Programming and Scripting
I have csv file with 30, 40 columns
Pasting just three column for problem description
I want to filter record if column 1 matches CN or DN then,
check for values in column 2 if column contain 1235, 1235 then in column 3 values must be sequence of 2345, 2345
and if column 2 contains 6789, 6789... (5 Replies)
Discussion started by: as7951
5 Replies
3. Shell Programming and Scripting
Dear folks
I have a map file of around 54K lines and some of the values in the second column have the same value and I want to find them and delete all of the same values. I looked over duplicate commands but my case is not to keep one of the duplicate values. I want to remove all of the same... (4 Replies)
Discussion started by: sajmar
4 Replies
4. Shell Programming and Scripting
Hi Gurus,
I have a file(weblog) as below
abc|xyz|123|agentcode=sample code abcdeeess,agentcode=sample code abcdeeess,agentcode=sample code abcdeeess|agentadd=abcd stereet 23343,agentadd=abcd stereet 23343
sss|wwq|999|agentcode=sample1 code wqwdeeess,gentcode=sample1 code... (4 Replies)
Discussion started by: ratheeshjulk
4 Replies
5. Shell Programming and Scripting
Hello,
I have a script that is generating a tab delimited output file.
num Name PCA_A1 PCA_A2 PCA_A3
0 compound_00 -3.5054 -1.1207 -2.4372
1 compound_01 -2.2641 0.4287 -1.6120
3 compound_03 -1.3053 1.8495 ... (3 Replies)
Discussion started by: LMHmedchem
3 Replies
6. Shell Programming and Scripting
Dear Gents,
Please can you help me to solve this problem.
Input file...
22057485 ,219 ,1050
22057485 ,223 ,1050
21897425 ,278 ,1050
21897425 ,279 ,1050
21897425 ,287 ,1050
20497465 ,602 ,1051
20517500 ,677 ,1051
20517500 ,681 ,1051
20577555 ,775 ,1052
20577555 ,778... (7 Replies)
Discussion started by: jiam912
7 Replies
7. Shell Programming and Scripting
Hi,
How to enumerate duplicate values, without sorting the file.
example
1 1
2 1
3 1
1 2
2 2
3 2
1 3
2 3
3 3
Where the first column have the repetead values without sorting,
I would like to get the value of the times that the value is repetead , as I show... (2 Replies)
Discussion started by: jiam912
2 Replies
8. UNIX for Dummies Questions & Answers
Hi, I've got a file that I'd like to uniquely sort based on column 2 (values in column 2 begin with "comp").
I tried sort -t -nuk2,3 file.txtBut got:
sort: multi-character tab `-nuk2,3'
"man sort" did not help me out
Any pointers?
Input:
Output: (5 Replies)
Discussion started by: pathunkathunk
5 Replies
9. Shell Programming and Scripting
hi to all
Does anyone know if there's a way to remove duplicate lines which we consider the same only if they have the first and the second column the same?
For example I have :
us2333 bbb 5
us2333 bbb 3
us2333 bbb 2
and I want to get
us2333 bbb 10
The thing is I cannot... (2 Replies)
Discussion started by: vlm
2 Replies
10. Shell Programming and Scripting
Hi
Ive been scratching over this for some time with no solution.
I have a file like this
1 bla bla 1
2 bla bla 2
4 bla bla 3
5 bla bla 1
6 bla bla 1
I want to remove consecutive occurrences of lines like bla bla 1, but the first column may be different.
Any ideasss?? (23 Replies)
Discussion started by: jamie_123
23 Replies