The changes you requested were not successful ...duplicate values ...

Ally

Registered User.
Local time
Today, 10:00
Joined
Sep 18, 2001
Messages
617
I've got the following error message, but cannot for the life of me work out why I'm getting it. I've tried attaching the db, but can only get it to 130kb, which is still too big.

Does anyone know why I'm getting it please?

"The changes you requested were not successful because they would create duplicate values in the index, primary key, or relationship. Change the data in the field or fields that contain duplicate data, remove the index, or redefine the index to permit duplicate entries and try again."
 
Check your tables. You've got an index set to 'no duplicates' and you're trying to enter a value which would result in an index being duplicated therefore Access is blowing a raspberry!

Have you compacted the db? This should reduce the size and you may then be able to attach it.

hth

shay :cool:
 
After you check your tables like Shay suggested, check your relationships, too. I often get bit by the "Duplicate Values" message when I have cascading updates in my table relationships, but build quick ad-hoc relationships in queries and then try to update records from there.

And after the compact/repair, make sure you zip it, too! That may make it small enoguh to post.
 
Yes I did compact, deleted tables etc, compacted, deleted, compacted and zipped every time, but still too big.

Will have a look at the tables and post back.

Thanks.
 
Deleted some more bits and managed to get it to 99kb!

Go to frmCustomer and click Add Stores Order. This will take you to an order form. Add the first couple of fields Delivery Note no and date and try to move to the next record and the error will appear.

Have noticed that Customer No is generating an autonumber, when it should be looking it up from the previous form: =[Forms]![frmCustomer]![Customerno] in the default property. If I swap it over, which I know is wrong, I get "the current field must match the join key ..."

CustomerNo is an autonumber, and CustomerID is a unique reference (no duplicates), but because it's a text field, decided to have CustomerNo as the primary key.
 

Attachments

Last edited:

Users who are viewing this thread

Back
Top Bottom