List:General Discussion« Previous MessageNext Message »
From:Michael Widenius Date:July 1 1999 7:05pm
Subject:finding distinct SET entries
View as plain text  
>>>>> "Christof" == Christof Damian <cdamian@stripped> writes:

Christof> Hello,
Christof> I got a table which contains a set, it looks something like this:

Christof> col1,col2
Christof> -------------
Christof> aaa,(a,b)
Christof> bbb,(e)
Christof> ccc,(a,d)
Christof> ddd,(a)

Christof> now I need a select which gives me:

Christof> a
Christof> b
Christof> d
Christof> e

Christof> SELECT BIT_OR(col2) gives me the result, but only as binary value and
Christof> there is no way to get back to the set values (or is there?). I also
Christof> have no idea how fast it is with big tables.



SELECT MAKE_SET(BIT_OR(col2),'a','b','c','d') ...


finding distinct SET entriesChristof Damian1 Jul
  • finding distinct SET entriesMichael Widenius1 Jul
  • Re: finding distinct SET entriesChristof Damian2 Jul
    • Re: finding distinct SET entriesMichael Widenius2 Jul
  • Re: finding distinct SET entriesMartin Ramsch2 Jul