I am trying to run an update query that I've run for years with no issues. This morning when I run it from code I get the dreaded "duplicate values" key violation error message. OK, so the first thing I normally do to try to debug is to run the query from the db query window and have the confirmation message tell me how many records are affected. Expecting the usual dialog boxes, something like: "YOu are about to update 2000 records" and then when I click OK, something like "50 records failed to update due to kv errors".
But now, when I run the update query from the db query window, I get NOTHING. No confirmation, and no errors. Where did my confirmation messages go?
In addition: I've checked for duplicate values in the incoming data. There are none. And the way I have my query structured, duplicate values that already exist in the table I'm updating should not matter.
Here's the query:
I have already tried repair/compact, and importing stuff into a new, blank db. No change.
What's going on? Why aren't I getting the query confirmation messages? What else could be causeing the KV error? Any ideas?
But now, when I run the update query from the db query window, I get NOTHING. No confirmation, and no errors. Where did my confirmation messages go?
In addition: I've checked for duplicate values in the incoming data. There are none. And the way I have my query structured, duplicate values that already exist in the table I'm updating should not matter.
Here's the query:
The PK in AttributeRepairs is PanelID-ImageNo-AssyNo-Repcode-RefdesUPDATE AR_Export1 LEFT JOIN AttributeRepairs ON (AR_Export1.ID = AttributeRepairs.PanelID) AND (AR_Export1.ImageNo = AttributeRepairs.ImageNo) AND (AR_Export1.Assyno = AttributeRepairs.AssyNo) AND (AR_Export1.RepCode = AttributeRepairs.RepCode) AND (AR_Export1.RefDes = AttributeRepairs.RefDes) SET AttributeRepairs.PanelID = ar_export1.id, AttributeRepairs.ImageNo = "unknown", AttributeRepairs.AssyNo = "0", AttributeRepairs.RepCode = ar_export1.repcode, AttributeRepairs.RefDes = ar_export1.refdes, AttributeRepairs.Pqty = ar_export1.pqty, AttributeRepairs.PartNumber = AR_EXPORT1.PARTNO, AttributeRepairs.POO = [pcacellresp];
I have already tried repair/compact, and importing stuff into a new, blank db. No change.
What's going on? Why aren't I getting the query confirmation messages? What else could be causeing the KV error? Any ideas?