November 2007 Entries
If you've ever done a UNION in SQL you may not have noticed that by default it actually does the same as a SELECT DISTINCT on the resulting data - so if you had the same 5 rows in two tables you'd get only 5 rows after the UNION. That's great most of the time, but what if you want all 10 rows? That's where UNION ALL comes in - that won't do a distinct and will get you every row.

Cheers Mr Sherwood for posing the question....

Bookmark with :
Digg It! DZone StumbleUpon Technorati Reddit Del.icio.us Newsvine Furl Blinklist