How can remove duplicates in a file using UNIX?
Answers were Sorted based on User's Feedback
Answer / j madhava rao
$sort -u filename will sorts the data and removes the duplicates lines from the output
| Is This Answer Correct ? | 17 Yes | 1 No |
Answer / vishwababu
You can use UNIQ to remove duplicates frm a file but it can
consider only same consecutive records.
Ex: if u hve records as
1 vishwa
1 Shruti
2 Ravi
3 Naveen
1 vishwa
and if u use UNIQ cmd, then you wil get vishwa, Ravi, Naveen
and vishwa.
So perform sort before using UNIQ so tat to avoid duplicates
| Is This Answer Correct ? | 7 Yes | 7 No |
Answer / prasad
Uniq -u File_name
It will remove duplicates records.
| Is This Answer Correct ? | 0 Yes | 2 No |
Where the datastage stored his repository?
Differentiate between data file and descriptor file?
How do you get log info into a file?
Enlist various types of routines in datastage.
diff between OLTP and OLAP? what TOP-DOWN and BOTTOM-UP Approach? which is best? what are Star Schema and Snow Flake Schema?
How many types of sorting methods are available in datastage?
what is initial load and incremental load
How many partitions does a node can have? Some body explain me clearly about the partitions and the nodes?
Suppose take my name "Reddyvaraprasad" From source it is coming Reddy vara prasad Need to get As Reddyvara prasad/
what is meta data? Explain? Where it is used?
What is the differentiate between data file and descriptor file?
1) In a dataset how to delete a single row? 2) i have 50 rows , i want to display 5-7 records only? How to write the sql query? 3)i have 40 rows,i want to display last row? write sql query?