Tony said:
Thank You...here is the SQL
INSERT INTO [Log table] ( [Circuit ID], [Billing #], [Circuit Type],
[Company Name], [Vendor Name], [Regional PICC Code], [LD PICC Code],
[Circuit Status], [Install Date], [Circuit Owner], Department,
[Contract Length], [Location Code], MRC, NRC, [Last Update], Name,
Notes )
SELECT [Circuit Info Table].[Circuit ID], [Circuit Info
Table].[Billing #], [Circuit Info Table].[Circuit Type], [Circuit
Info Table].[Company Name], [Circuit Info Table].[Vendor Name],
[Circuit Info Table].[Regional PICC Code], [Circuit Info Table].[LD
PICC Code], [Circuit Info Table].[Circuit Status], [Circuit Info
Table].[Install Date], [Circuit Info Table].[Circuit Owner], [Circuit
Info Table].Department, [Circuit Info Table].[Contract Length],
[Circuit Info Table].[Location Code], [Circuit Info Table].MRC,
[Circuit Info Table].NRC, [Circuit Info Table].[Last Update],
[Circuit Info Table].Name, [Circuit Info Table].Notes FROM [Circuit
Info Table];
This is fine so far as it goes, Tony, but there's nothing in the query
that would limit the records selected from [Circuit Info Table] to just
the one that was edited on your form. If CircuitID is the primary key
of [Circuit Info Table], then you might amend your query to refer to
that field on the form in a WHERE clause, like this:
INSERT INTO [Log table] (
[Circuit ID], [Billing #], [Circuit Type], [Company Name],
[Vendor Name], [Regional PICC Code], [LD PICC Code],
[Circuit Status], [Install Date], [Circuit Owner], Department,
[Contract Length], [Location Code], MRC, NRC,
[Last Update], [Name], Notes )
SELECT
[Circuit ID], [Billing #], [Circuit Type], [Company Name],
[Vendor Name], [Regional PICC Code], [LD PICC Code],
[Circuit Status], [Install Date], [Circuit Owner], Department,
[Contract Length], [Location Code], MRC, NRC,
[Last Update], [Name], Notes
FROM [Circuit Info Table]
WHERE [Circuit ID]=[Forms]![CircuitInfoForm]![Circuit ID];
That's assuming that your form is named "CircuitInfoForm", and it has a
control on it named "Circuit ID" that currently holds the primary key of
the record you want to append.
My reformatting of your SQL is just for clarity and convenience. The
WHERE clause is the only significant change. However, you should be
able to copy and paste my revision into the SQL View of your query,
correct the form and control names, and have it work.
--
Dirk Goldgar, MS Access MVP
www.datagnostics.com
(please reply to the newsgroup)