Prev: Getting info from two tables with disimilar headings
Next: howto copy only newer OrderID data(and the other fields) from one
From: Bartus on 1 Mar 2010 11:36 howto copy only newer OrderID data(and the other fields) from one table to another table So the new table is updated only with the new OrderID and the OrderID's already copyied earlier are not also added everytime. i use the append query i think and need certainly some criteria (filters)? Can somebody help me out, please? Thank you! Bart
From: Bart on 3 Mar 2010 06:14
On 1 mrt, 18:27, Marshall Barton <marshbar...(a)wowway.com> wrote: > Bartus wrote: > >howto copy only newer OrderID data(and the other fields) from one > >table to another table > > >So the new table is updated only with the new OrderID and the > >OrderID's already copyied earlier are not also added everytime. > > >i use the append query i think and need certainly some criteria > >(filters)? > > INSERT INTO table2 (OrderID, f1, f2, ...) > SELECT OrderID, f1, f2, ... > FROM table1 INNER JOIN table2 > ON table1.key = table2.key > WHERE tabl2.key Is Null > > -- > Marsh > MVP [MS Access] INSERT INTO Bestellingen_copy (BestellingID) SELECT BestellingID FROM Bestellingen_1 INNER JOIN Bestellingen_copy ON Bestellingen_1.BestellingID= Bestellingen_copy.BestellingID WHERE Bestellingen_copy.BestellingID Is Null I try your code and the system says BestellingID can point out more then one source.. THe source and destination tables have no key(-ID). Source table: Bestellingen_1 Dest. table: Bestellingen_copy Can you help me out? Thank you Bart |