Why is this not an updatable query?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

All I am trying to do is to change the status of a shipment. I have the
status field set to a look up with 3 values in it. Every time I try to
change a value I get a sound from my speakers and it will not change the
value to the status I just selected?

SELECT tblAlerts.ShipDate, tblAlerts.[Airline Airbill], tblAlerts.CompanyId,
tblAlerts.AirportFrom, tblAlerts.AirportTo, tblAlerts.Airline,
tblAlerts.Pieces, tblAlerts.Weight, tblAlerts.Comments, tblAlerts.Status,
tblAlerts.AlertId
FROM tblAlerts
GROUP BY tblAlerts.ShipDate, tblAlerts.[Airline Airbill],
tblAlerts.CompanyId, tblAlerts.AirportFrom, tblAlerts.AirportTo,
tblAlerts.Airline, tblAlerts.Pieces, tblAlerts.Weight, tblAlerts.Comments,
tblAlerts.Status, tblAlerts.AlertId
HAVING ((Not (tblAlerts.[Airline Airbill]) Is Null) AND
((tblAlerts.CompanyId)<>"410926") AND ((tblAlerts.Status)<>"Recovered"))
ORDER BY tblAlerts.ShipDate DESC , tblAlerts.[Airline Airbill] DESC ,
tblAlerts.AirportTo DESC;

any help would be apppreciated.
 
Because this is a GROUP BY query. i.e. each row is potentially from 1 or
more records. How would Access decide which of those rows to update??

For example

ID Name Age
1 John 10
2 Joe 20
3 John 15

If you did a group by on this to get the sum of ages, the result would be

Name SumOfAge
John 35
Joe 20

If you change the 35 to be 37, does ID 1 or ID 3 change?
 

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

Similar Threads

Code Not Working 3
Formula for Select Query 2
Looping Macro to scrap multiple pages in Mainframe 2
Why Doesn't This Work 5
query- airlines 1
query on airlines 1
Union Query 1
Help Me Fix This Querry 1

Back
Top