G
Guest
Sorry if this is answered elsewhere - looked but couldn't find
I have inherited a db, one part of the vba code of which updates a table using an INSERT INTO query, gathering info from a second table. The SELECT part of the query definitely produces records which duplicates entries in the primary key fields already in the first table
My question is, what SHOULD happen when this code is run? It seems to be cheerfully dropping all duplicates and only inserting new records, with not a flicker of an error, but I thought it should try to insert the duplicates and then cause an error because of the primary key. Have I misunderstood
Thx in advance for all assistance
Eri
P.S. I know that this has no mention of forms - sorry! If there's a more appropriate forum for this question, can somebody point me in the right direction?
I have inherited a db, one part of the vba code of which updates a table using an INSERT INTO query, gathering info from a second table. The SELECT part of the query definitely produces records which duplicates entries in the primary key fields already in the first table
My question is, what SHOULD happen when this code is run? It seems to be cheerfully dropping all duplicates and only inserting new records, with not a flicker of an error, but I thought it should try to insert the duplicates and then cause an error because of the primary key. Have I misunderstood
Thx in advance for all assistance
Eri
P.S. I know that this has no mention of forms - sorry! If there's a more appropriate forum for this question, can somebody point me in the right direction?