how to find out the repeated value from table using groupby
function?
Answers were Sorted based on User's Feedback
Answer / arshi
SELECT COUNT(CoumnName) AS Expr1
FROM Tablename
GROUP BY CoumnName
HAVING (COUNT(CoumnName) > 1)
| Is This Answer Correct ? | 8 Yes | 0 No |
Answer / karthik
select eno,count(1) cnt from emp
group by eno having count(1) > 1;
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / navin.cp
SELECT COUNT(Column_Name) FROM Table_Name WHERE (Condition)
GROUP BY Column_Name
| Is This Answer Correct ? | 0 Yes | 3 No |
I have a table Events Events containing cardno,time,id,name--each id has a cardno my requirement is every day each employee swipe the card several times i want to calculate first and last time of each card the output should be name 1 2 6 7 in out in out holiday holiday xxx 09:30 06:30 09:40 06:45 where 1,2...... are dates for example january 1,2, etc. 6 and 7 are saturday and sunday how it is posssible
What is the difference between 2-Tier architecture and 3-Tier architecture
15 Answers CTS, MCN Solutions, Oracle,
What is the difference between referencing and joining?
What is mean by "fill factor" ? and what is mean by "Index "in sql?
What is the difference between IN and EXISTS operators in SQL Server?
9 Answers ASD Lab, CSC, Intelligroup,
How to add code to the existing article (using improve article)?
What is difference beteen Migration and Upgrdation?
Explain the benefits of user-defined functions?
When to use Inner join & when to use subquery?
How to defragment table indexes?
What is de-normalization in sql database administration? Give examples?
select the 3rd maximum salary from sql server database if 4 (just an example In practically I may not know the exact situation) of the highest salaries are equal.
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)