Update Query to Replace All Data in Field

jrub

Registered User.
Local time
Yesterday, 23:52
Joined
Dec 11, 2012
Messages
52
Hi All,

Is it possible for an update query to simply replace all the data in a table's field with the results from a query?

For example, I have Table A with the field Years. This table performs various calculations within based on the field Years.

I would like an update query that simply replaces the Years field data in Table A with a new set of years based on a query's search criteria.

When I run the below query, I get an error saying the query must be updateable- but Im not trying to update the query, rather the Table

I've attached a photo to help illustrate.

Untitled.png


Thanks
 
What exactly is your database about - what subject matter? Do you have any specifications or business rules/facts?

The advice of anyone with database experience is do not store Calculated values.
That appears to be what NumberOfDups represents, but that's a guess.

Your question is about TableA and a field Years, but your photo has 2 different tables.

I have no idea what the"dups" are dups of, but I can say that Update queries can be quite unforgiving and you could really mess up some data.
 

Users who are viewing this thread

Back
Top Bottom