Insert Data from one table to another

N

neshev

Hi,
I have 2 identical tables. Tbl_Items & Tbl_History. I have a form that asks
the user to select a client. When the user selects the client, I want to
transfer any records with this Client name in tbl_History into tbl_Items. it
is an inspection database and so I need to carry out this operation. Any help
will be really appreciated

Regards

Neil
 
M

Michel Walsh

Hi,



INSERT INTO archiveTable (listOfFields) SELECT (listOfFields) FROM oldTable
WHERE oldTable.ClientID= 1004



where listOfFields is a list of coma delimited fields names. Both list must
have the same number of fields and they must "match" (compatible by data
type).

Hoping it may help,
Vanderghast, Access MVP
 
Top