DOCUMENT #685
     =======================================================================
     HOT TIP:  MAKE OUTER JOINS FASTER
     =======================================================================
     Product:  R:BASE             Version :  3.1 or Higher
     =======================================================================
     Area   :  PROGRAMMING        Category:  VIEWS                 
     =======================================================================
 
 
     By default, the UNION operator in the SELECT command is DISTINCT.  
     It checks for possible duplicate rows before displaying any data.  
     If you are retrieving thousands of rows this can be slow.  Instead, 
     use UNION ALL in your SELECT command.  All the rows will be retrieved, 
     including duplicates, if any, but the command will execute considerably 
     faster.  
 
     Use:
 
       SELECT ....... +
       UNION ALL +
       SELECT ....... +
 
     instead of:
 
       SELECT ....... +
       UNION +
       SELECT ....... +