UNION & UNION ALL

UNION va se comporter comme un DISTINCT UNION ALL va conserver les enregistrements des différents select.

Exemple : 

declare @t1 table ( ids  varchar(50) )
declare @t2 table ( ids  varchar(50) )
insert into @t1 ( ids ) values ('tutu')
insert into @t1 ( ids ) values ('tutu')
insert into @t1 ( ids ) values ('toto')
insert into @t2 ( ids ) values ('toto')
insert into @t2 ( ids ) values ('toto')
insert into @t2 ( ids ) values ('tutu')
select ids from @t1 union select ids from @t2 
select ids from @t1 union all select ids from @t2