A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
SQL query needed
Joined: Oct 26, 2010
Mar 06, 2013 05:44:22
I am a student on Computer Science and not having much knowledge. So please don't mind if my quesrion is silly.
I need to write a sql query to group by a column where column has duplicate values( having count more than one)
Please help me out.
Joined: Apr 04, 2006
Mar 06, 2013 06:19:53
Hi Nagendra ,
It would be really helpful if you can
tell us details
about what you've tried so far and the problem you're facing.
Tushar (SCJP 1.5)
Joined: Jan 19, 2012
Mar 19, 2013 14:26:09
As per what i have understood,
Let x be the column you wanted to find duplicates on,
clause on x then followed by
clause using the count function
For example: Select x from sometable group by x having count(x) > 1
I agree. Here's the link:
subject: SQL query needed
Exception while retrieving the result from resultset
Using Indexing concept for performance ?
export query from table column to text file
How to get table name from oracle query?
HQL to get all the records in one table but in not other
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014