Friday, April 29, 2016

MySql Query - find records from one table which don't exist in another

MySql Query - find records from one table which don't exist in another:-

Table 1:-

social_auth_email

email varchar(75)

Table 2 :-

 studentdetail

email varchar(75)

Then below query for find non duplicate records :-

SELECT sa.email  FROM   social_auth_email as sa LEFT OUTER JOIN studentdetail as htc   ON (sa.email=htc.email)   WHERE htc.email IS NULL

1 comment:

Trupti Parmar said...

Thanks for providing such nice information to us. It provides such amazing information on care/as well Health/. The post is really helpful and very much thanks to you. The information can be really helpful on health, care as well as on examhelp/ tips. The post is really helpful.
RBSE 12th Board result 2017
ICSE 10th result 2017