Discussions Populaires Dans la Communauté SQL Plus

S'abonner

Questionnez la Communauté


Ask any professional question and get answers from other specialists.

Stream language
Balaji Prakash's image
La question a été ajoutée par Balaji Prakash Data Analyst Systech Solutions
Depuis 7 années

How can i fetch duplicate data's from a table?‎

I completed my graduation last year and i am getting started with SQL. can anyone help me to solve this query.  Table name is Employee and it has the following fields EM‎ ... Voir Plus

Réponses:
34
Adeptes:
Vues:
104
Vote Count:
0
La réponse doit contenir un minimum de 25 caractères.
jamal mohammed's image
La question a été ajoutée par jamal mohammed مبرمج +ومحاسب أقساط في شركه الخولاني الخولاني بيتي
Depuis 8 années
Réponses:
2
Adeptes:
Vues:
186
Vote Count:
0
La réponse doit contenir un minimum de 25 caractères.
Rupesh Kumar's image  
La répondre a été ajoutée par  Rupesh Kumar, Consultant in Oracle BRM, Cubastion Consulting Pvt. Ltd.
Depuis 7 années

Expecting EMPNO is essential/primary key and ENAME has duplicate values then you can use following SQL. select ENAME from EMPLOYEE group by ENAME having count(ENAME) > ... Voir Plus

Signaler CV
Nadjib Benkhellat's image  
La répondre a été ajoutée par  Nadjib Benkhellat, Algiers, SOFTWAREENGINEERINGMANAGER at I2B
Depuis 8 années

Sadly i can't yet understand your question!!! please clarify so i can may be help you.... are you talking about finding developers (c#,java, sql, ...) or finding any ... Voir Plus

Signaler CV
Sebin Cheriyan's image  
La répondre a été ajoutée par  Sebin Cheriyan, Data Analyst, Tata Consultancy Services - India
Depuis 5 années

Use Analytical Functions (My Answer is based on Oracle). For example if you have 4 records in your Employee as follows and you want to delete duplicate records.   1 Jhon ... Voir Plus

Signaler CV
Default profile image  
La répondre a été ajoutée par  Utilisateur supprimé
Depuis 6 années

select EMPNO, ENAME, SAL, JOB, DEPTNO from employee group by EMPNO, ENAME, SAL, JOB, DEPTNO having count(*)>=2;

Signaler CV
heidar yousef's image  
La répondre a été ajoutée par  heidar yousef, Analyst Programmer & Team Leader, Municipality of Qatif Municipality - Eastern Region
Depuis 6 années

SELECT column_name  FROM tablename GROUP BY column_name  HAVING COUNT(column_name ) > 1

Signaler CV
Indlamuri  Hari Krishna's image  
La répondre a été ajoutée par  Indlamuri Hari Krishna, DataBase Developer, kolla Soft pvt. ltd
Depuis 6 années

select distinct * from employee;  

Signaler CV
Samuel Bolaji's image  
La répondre a été ajoutée par  Samuel Bolaji, Oracle DBA, Mahindra Comviva
Depuis 6 années

select column1, column2..., count(columnlast) from table_name where (all_conditions_if_required) group by columnlast ------ (if it is the comlumn with duplicate data) hav ... Voir Plus

Signaler CV
Default profile image  
La répondre a été ajoutée par  Utilisateur supprimé
Depuis 6 années

select title, uk_release_date, count(*) from films group by title, uk_release_date having count(*) > 1;

Signaler CV