Filter for unique records

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

i have a table with
id seq group
1 AA 1
2 AB 1
3 AA 2
4 AB 2
5 ABC 3
6 BCA 3
7 ABC 4
8 BCA 4

now, i want to filter this data set so that, it comes with unique seq only
like
1 AA 1
2 AB 1
5 ABC 3
6 BCA 3

but, remember, this is not what I want??

1 AA 1
4 AB 2
5 ABC 3
8 BCA 4

that means in the data set there are same seqs assigned to different Group,
but i want all this similar seq to be in a single group and delete other
groups with duplicated seq. i tried

SELECT grouping.seq, last(grouping.groupno)
FROM grouping group by grouping.seq;

which gave me the unique seq but with results what i did not wanted (above
example)

Please, help me
 
Hello. In the querie use the Totals option (it's the symbol of sum in excel)
then in the column of Total row choose First.

I hope it helps.

Regards,
Marco
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top