home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.databases.oracle      Overblown overpriced overengineered SHIT      2,288 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 1,246 of 2,288   
   Spare Brain to All   
   How to avoid duplicates here...?   
   07 Apr 04 22:16:25   
   
   XPost: comp.databases.oracle.misc, comp.databases.oracle.server   
   From: spare_brain@yahoo.com   
      
   Hi,   
      
   I had a problem where I had to limit the rows returned - return only the   
   rows between N and M. I accomplished it using a SQL that looks something   
   like this:   
      
      
   SELECT rownum, emp_name from EMPLOYEE   
         WHERE dept = 'hardware'   
         group by rownum, emp_name having rownum between 10 and 15   
      
   Now, as it so happens, there could be multiple entries for any given   
   employee. I am getting multiple rows for the same employee! Is there a way   
   to introduce a "distinct" on just the emp_name? How else to achieve this? If   
   I use "select distinct rownum, emp_name..." it does not prevent multiple   
   employees from showing up!   
      
   Please post your valuable suggestions to the newsgroup.   
      
   Thanks!   
   SB   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca