Action queries changing when reopened in design view

K

Kendra

Hello,

I am rephrasing/simplifying a question I posted earlier so
that somebody might know what's going wrong.

I am using two action queries in a form. A delete query
and an append query. I originally created the queries as
recommended in Access help, the basic form of each query
is as follows:

Delete query (please imagine this in design view)

Field: tbl_dataentry adminstatus date
Table: tbl_dataentry tbl_dataentry tbl_dataentry
Delete: from where where
Criteria: [adminstatus]="decline"
[adminstatus]="decline" etc...

Append query (please imagine this in design view):
Field: Record_ID Date
Table: tbl_dataentry tbl_dataentry
Sort:
Append to: Record_id Date
Criteria: [Adminstatus]="accept" [Adminstatus]="accept"
etc...

However, when I reopen the queries in design view,
their design has changed from what I originally created.
Instead of listing the criteria ([Adminstatus]="accept"
for the append query and [Adminstatus]="deline" for the
delete query) under each column of my query design view
(as shown in the query) the very last column of the append
says "Accept" and "Accept" and "Accept" and the very last
column of the delete query says "Decline" and "Decline"
and "Decline" in the criteria section (the field section
on this last column is the table's name -- tbl_dataentry).

I did not add the last column to my queries' design, nor
did I delete the criteria sections. I am using these
queries in a macro that combines the two queries. I
suspect that running the macro with the queries is what
altered them, but my queries could just be wrong.

Any suggestions?
Thank you for your time,
Kendra
 
J

John Spencer (MVP)

It would help if you posted the SQL statement vice trying to post a
representation of the view.

Can you copy and post the SQL of your query?

(Possibly unneeded instructions follow)
Open the query
Select View:Sql from the Menu
Select all the text
Copy it
Paste it into the message
 
T

Ted Allen

As John mentioned it would be easier to see the sql, but
in your examples it seems to me that you are typing the
fieldname an = sign and then the criteria all in the
criteria row. When using the query builder you would
generally put just the right side of the expression
beneath the appropriate field name. In your case you
would put "accept" or "decline" in the [adminstatus]
column. Maybe this is what you are doing and I
misunderstood your post, but I thought I would mention it
just in case.

HTH, Ted Allen
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top