Append query

G

Guest

I created an append query,and it was agood idea to have the info in table1
(that's linked to the inbox of Outlook),copied to table2,but the problem is
that when a new record is created in table1(a new mail is received),table2 is
not updated with the last changes, itried to run this append query in order
to cascade the new record to table2 ,but the recordes were doubled.
Can you help,i need that whenever a new record is added to table1,it's added
also to table2 ,automatically or by clicking on a button
Regards
 
G

Guest

you need to string together the append, followed by a delete of the temp
table, followed by a create of the temp table...

so that after each append - the temp table is effectively flushed out....so
you do not repeat appending records that were previously appended
 
A

aaron.kempf

if you were using Access Data Projects then you could put multiple SQL
Statements inside of a single sproc

-Aaron
 
G

Guest

Thank you very much,
Please note that i'm still new to Access, could you please explain this in
details

Regards
 
G

Guest

Well - if I understand - your Table 1 is linked to outlook and acting as a
temp table that feeds to Table 2. And you are executing that feed to Table
2 via an Append Query.

You need therefore to delete the records of Table 1 after you run an Append
Query to avoid them being re-appended each time you do this.

If there are not alot of records you could simply open Table 1 and manually
delete each record.

If there are many records it is easier to delete the table. Before you do
this you first want to copy a Table 1 template to re-use....... - basic right
click copy / paste - and it will prompt you if you want data & structure or
structure only. You want Structure Only. Give it a name like Table1Template.

Then after you delete Table 1 - copy Table1Template and name it Table 1.

Note that you have to stick with the Table 1 name without change otherwise
you will break the logical link that exists to outlook - it is looking for
the correct table name.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top