Append Queries...

V

Van T. Dinh

There are 2 syntaxes for the INSERT INTO... SQL.

* Multiple-record append query:

INSERT INTO target [(field1[, field2[, ...]])] [IN
externaldatabase]
SELECT [source.]field1[, field2[, ...]
FROM tableexpression

* Single-record append query:

INSERT INTO target [(field1[, field2[, ...]])]
VALUES (value1[, value2[, ...])

In your case, you will need to use the 2nd syntax. Check
Access Help for more info.

HTH
Van T. Dinh
MVP (Access)

-----Original Message-----
Hi,

I am trying to create an "Append Query" that adds a new
record to a database table 'Table1'. I do not want to copy
information from another table just add a new record
to 'Table1'. I can't seem to get it to work, when i run it
no records are appended?? How do i use a query to create a
new record for a single table??
 
D

Darryn Ross

I am getting a syntax error when trying to run the query in access.
There are 2 syntaxes for the INSERT INTO... SQL.

* Multiple-record append query:

INSERT INTO target [(field1[, field2[, ...]])] [IN
externaldatabase]
SELECT [source.]field1[, field2[, ...]
FROM tableexpression

* Single-record append query:

INSERT INTO target [(field1[, field2[, ...]])]
VALUES (value1[, value2[, ...])

In your case, you will need to use the 2nd syntax. Check
Access Help for more info.

HTH
Van T. Dinh
MVP (Access)

-----Original Message-----
Hi,

I am trying to create an "Append Query" that adds a new
record to a database table 'Table1'. I do not want to copy
information from another table just add a new record
to 'Table1'. I can't seem to get it to work, when i run it
no records are appended?? How do i use a query to create a
new record for a single table??
 
V

Van T. Dinh

Post the relevant Structure of the Source & Dest Tables, the SQL String of
your Query and if the error is in VBA code, post the relevant code.

--
HTH
Van T. Dinh
MVP (Access)



I am getting a syntax error when trying to run the query in access.
 
Top