Results 1 to 2 of 2
- 06-15-2011, 11:48 AM #1Member
- Join Date
- Jun 2011
- Rep Power
How to get unique rows from a table
i've a file with data in the following format
id element1 element2 element3 element4 elemet5
1 A B C NULL NULL
2 A D NULL NULL NULL
3 C B A NULL NULL
4 A D NULL NULL NULL
5 F C A O B
i want to get the unique rows only ,in above example rows with ids 1 and 3 are redundant(have the same elements,the sequence doesn't matter) and rows 2 and 4 are also redundant.
i would like to know the most efficient way to get the unique rows from the above table.
Thank you very much.
- 06-15-2011, 12:08 PM #2
Hi, You can read need's data and then put it in special collection, which can't has duplicate elements as like Set.Skype: petrarsentev
- By mn1247 in forum JDBCReplies: 0Last Post: 03-03-2011, 03:20 PM
- By kulangotski in forum JDBCReplies: 7Last Post: 01-13-2011, 12:48 PM
- By xcallmejudasx in forum JDBCReplies: 1Last Post: 04-23-2009, 07:55 PM
- By raycini in forum JavaServer Faces (JSF)Replies: 2Last Post: 04-20-2009, 08:24 AM
- By Java Tip in forum SWT TipsReplies: 0Last Post: 07-11-2008, 04:31 PM