Solved

Microsoft Access 2010 Update Statement not updateable.

Posted on 2013-01-16
3
360 Views
Last Modified: 2013-01-16
I cannot understand what Access means when it says this statement must use an updateable query.

t2 has one row, t3 has three rows.

update t2 set sys_id = (select max(sys_id) + 1 from t3)

Is there a way to make this work in Access 2010?
0
Comment
Question by:claghorn
3 Comments
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 38783378
maybe

update t2,t3 set sys_id = dmax("sys_id","t3") +1
0
 

Author Closing Comment

by:claghorn
ID: 38783512
I used this thanks.

update t2 set t2.sys_id = dmax("sys_id","t3") +1
0
 
LVL 77

Expert Comment

by:peter57r
ID: 38783546
Any update query which involves an sql  'Group By' or any sql aggregate  function Max(), Min() Avg() etc will not work in Access.  It gives the message you have seen.

The workaround is often to use domain functions DMax() , DMin(), DAvg() etc as in the solution  posted by Capricorn1.
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction When developing Access applications, often we need to know whether an object exists.  This article presents a quick and reliable routine to determine if an object exists without that object being opened. If you wanted to inspect/ite…
Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question