Darren DICK
d.dick at uws.edu.au
Mon May 12 21:42:34 CDT 2003
Never mind I got it using the Find Unmatched Query wizard then turning it into an append query Thanks all Darren ----- Original Message ----- From: "Darren DICK" <d.dick at uws.edu.au> To: <accessd at databaseadvisors.com> Sent: Tuesday, May 13, 2003 12:23 PM Subject: [AccessD] A2K: Need a Smarter Append Query > Hello all > I have an append query that gets a few columns from one table(Bookings) and puts those > few columns into another table (tblWarnings) Based on today's date. Very basic, see SQL below. > > What I really want is for the SQL to only get bookings from the table Bookings and put them into > tblWarnings if they are not already in tblBookings. > > So if tblWarnings already has bookings 1, 2 and 3 from table bookings. > I don't want the SQL to get them again if I run it. But if I add record 4 to table Bookings then > run the append SQL, I do want it to get record 4 and ignore the other 3. Make sense? > > INSERT INTO tblWarnings ( BookingID, BookingDate, BookingTime, Cancelled ) > SELECT Bookings.BookingID, Bookings.BookingDate, Bookings.BookingTime, Bookings.Cancelled > FROM Bookings > WHERE (((Bookings.BookingDate)=Date())); > > Many thanks in advance > > Darren > _______________________________________________ > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com