mysql - Inserting distinct entries into the database -


I have two tables with the same area Table A contains 7160 records and table B 7130 records. Now I want to enter B in different record tables from Table A. like it does not have any duplicate entry in B. How should I go about doing this?

It basically selects those records which are in A which are not in B. This will work, but you may have to make more changes to identify the fields you use to uniquely identify the record. In this example I used the field 'id', but you may have to change it in Effield 1 = Bifield 1 and Effield 2 = Bifffield 2 etc.

(select A. * Table A, on the bottom A tab = B, AID = BID, where BID is zero)

Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -