SQL INSERT Statement in MS Access

  • Thread starter Thread starter Burt
  • Start date Start date
B

Burt

Hi,

I'm trying to insert a record into a MS Access Table. I
generally use "Set MyTable = CurrentDB.OpenRecoordset
(SELECT * FROM MyTable)" to open the table, then use
Addnew to update the table with a new record. However, I
know I can use the INSERT SQL statement, but cannot seem
to get the syntax right.

If anyone knows the correct syntax, please share knowledge.

Thanks,

Burt
 
This is a generic way to do what you seek.

INSERT INTO MyTable (Field1, Field2, Field3, Field4 )
SELECT Value1, Value2, Value3, Value4;
 
Ken,

Thanks,

Burt
-----Original Message-----
This is a generic way to do what you seek.

INSERT INTO MyTable (Field1, Field2, Field3, Field4 )
SELECT Value1, Value2, Value3, Value4;


--

Ken Snell
<MS ACCESS MVP>




.
 
Back
Top