I am trying an Append Query for the 1st time. I followed the detailed instructions from MS and I get "Query must have at least one destination field." Any ideas?
I am trying an Append Query for the 1st time. I followed the detailed instructions from MS and I get "Query must have at least one destination field." Any ideas?
You have selected the fields/expressions that will be read, but not assigned any fields these data shall be written to.
Why not show the query sql?![]()
Please use # icon on toolbar when posting code snippets.
Cross Posting: https://www.excelguru.ca/content.php?184
Debugging Access: https://www.youtube.com/results?sear...bug+access+vba
I don't understand your answer. what do you mean "show the query sql"
If sql refers to Structured Query Language, I don't know how to show it. Can I do that while in MS Access?
from the query builder you can right click and select ‘view sql’. Or bottom right there is an option to select sql. And in the ribbon in the left you can select SQL view. Worst case, show a screen shot of your query builder windowwhat do you mean "show the query sql"
Switch the query builder to SQLView then copy/paste the text that it displays.
And in Access versions later than 2010, I think can right click over query in Navigation pane and select SQLView. Unfortunately, can't use my 2021 version now to confirm.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
SELECT
FROM [Debit Card Master Table] INNER JOIN [Card Table] ON ([Debit Card Master Table].[Bank Phone] = [Card Table].[Bank Phone Number]) AND ([Debit Card Master Table].[security code] = [Card Table].[Security Code]) AND ([Debit Card Master Table].[Persons name on debit card] = [Card Table].[Name on Card]) AND ([Debit Card Master Table].[Expire Date] = [Card Table].[Expire Date]) AND ([Debit Card Master Table].Status = [Card Table].Status) AND ([Debit Card Master Table].[Card Number] = [Card Table].[Card Number]) AND ([Debit Card Master Table].[Name of Bk or Cu] = [Card Table].[Bank or CU name]);
does this make sense to you?
What else can I do?
That's just joining two tables on multiple field pairs. It does not add records. An APPEND query would start with INSERT INTO.
Why are you wanting to use an APPEND anyway?
Might review https://www.accessforums.net/showthread.php?t=90984
Could provide db for analysis. Follow instructions at bottom of my post.
Last edited by June7; 06-26-2025 at 08:02 PM.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
That is a basic sql statement- as suggested in post #2 you have not specified a destination table or the fields. Your sql should look something like
INSERT INTO tableName (fld1, fld2….)
followed by your select statement
as an aside, don’t have spaces in table and field names
The query you are showing is a Select query (i.e. just for viewing)
To Make a table you need an Into statement also
SELECT Booked1_Q.Sales_Order INTO TestTable1_t
FROM Booked1_Q;
To Append you need an Insert Into statement. The insert into fields need to match the select fields. This is only a one field insert.
INSERTINTO TestTable1_t ( Sales_Order )
SELECT Booked1_Q.Sales_Order
FROM Booked1_Q;
Or you can choose the Make Table option or the Append option in the Query Design window.
![]()
You have only done the first 4 items, you have not selected a destination table or mapped the fieldsThese are the instructions I used.
If instructions are not enough, have a look at some videos.
Please use # icon on toolbar when posting code snippets.
Cross Posting: https://www.excelguru.ca/content.php?184
Debugging Access: https://www.youtube.com/results?sear...bug+access+vba