How do I create a query which is only a snapshot - no updating

E

Elfey1001

How do I restrict a query from updating. i.e. it is only a snapshot. The
query in question is retrieving data from 3 tables. I only want to see the
data and not update it.

The background is that I have a form with one combo box and a subform based
on the query above, when I select a record in the combo box it shows me the
data in the subform exactly as I requested.

However the problem is that when I close the form somehow the top record in
the query gets overwritten (and therefore the data in the tables) with the
last data that was shown in the subform.
I only want to view the data not update it.
Can anyone advise please!
 
E

Elfey1001

Elfey1001 said:
How do I restrict a query from updating. i.e. it is only a snapshot. The
query in question is retrieving data from 3 tables. I only want to see the
data and not update it.

The background is that I have a form with one combo box and a subform based
on the query above, when I select a record in the combo box it shows me the
data in the subform exactly as I requested.

However the problem is that when I close the form somehow the top record in
the query gets overwritten (and therefore the data in the tables) with the
last data that was shown in the subform.
I only want to view the data not update it.
Can anyone advise please!
 
J

Jeff Boyce

One approach I've seen to accomplish this is to convert the query to a
Totals query, using GroupBy for every field the query displays. Since the
values are "aggregated", they aren't updatable.

But based on your description, I suspect your forms design needs a bit more
work. In a standard main form/subform design, you don't get records
overwriting other records.

Is there any chance that combobox is bound to an underlying field in a
table?

It all starts with the data ... "how" you do something depends on "what" you
have to work with.

Consider posting a description of your data structure, and posting the SQL
statement of your query.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 

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