Filter data from multiple sql columns

0

I need help with a database, it would make a distinct with several columns, for example:

andtheoutputwouldbe:

Would you like to do this on the sql server?

Thank you in advance

    
asked by anonymous 15.04.2016 / 09:09

1 answer

0
select distinct coluna
from
(
 select coluna1 coluna from tabela
 union
 select coluna2 from tabela
 union
 select coluna3 from tabela
 union
 select coluna4 from tabela
)
    
15.04.2016 / 16:58