UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Conversion From 2007 To 2010, Office 2010    
 
   
Ironangel
post Apr 3 2012, 01:15 PM
Post #1

New Member
Posts: 3



I just recently had to switch our office system from Office 2007 to 2010. The Access database will not allow me to enter data in the table or the form. I receive the following message: "The changes you requested to the table 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"

I have never had this problem and the information that I am entering is all new information..... HELP!!!!! Please
Go to the top of the page
 
+
doctor9
post Apr 3 2012, 01:29 PM
Post #2

UtterAccess VIP
Posts: 9,304
From: Wisconsin



IronAngel,

(IMG:style_emoticons/default/welcome2UA.gif)

A good place to start would be to list your table's fields, particularly noting any fields that are set up with unusual Index properties. Go ahead and open up your table in Design View, check each field, and note which ones have something besides "No" next to the "Indexed" property. You may be surprised to spot the problem as you're doing this, so don't skip this step. (IMG:style_emoticons/default/smile.gif)

If possible, list your fields along thse lines:

CustomerID [Primary Key, Autonumber]
strFirstName
strLastName
strSocialSecurityNumber [Indexed, No Duplicates]
lngStateID [Foreign Key to tblStates.StateID]
etc.

From there, we may be able to help you find which field(s) are being duplicated by your data entry.

Hope this helps,

Dennis
Go to the top of the page
 
+
Ironangel
post Apr 3 2012, 01:45 PM
Post #3

New Member
Posts: 3



Thanks Dennis!

So what you are saying is that each field should have Yes(Duplicates OK) . . My primary key is based on the social security number.

Thanks
Go to the top of the page
 
+
Ironangel
post Apr 3 2012, 01:47 PM
Post #4

New Member
Posts: 3



I tried changing the first name field to allow duplicates in the index and it told me:


This error can be caused by one of the following:

The maximum number of columns allowed in a table or the maximum number of locks for a single file is exceeded.
The indexed property of a field is changed from Yes (Duplicates OK) to Yes (No Duplicates) when duplicate data exists in the table.
An expression is not specified in the Expression property of a calculated field.
If the maximum number of locks per file was exceeded, you can increase the number by editing a registry entry. However, this is not a recommended option.

If you use Registry Editor incorrectly, you could cause serious problems that require you to reinstall the operating system. Microsoft cannot guarantee that you can solve problems that result from using Registry Editor incorrectly. Use Registry Editor at your own risk.

Make a backup of the registry. Find the MaxLocksPerFile registry value by using the Windows Registry Editor, and then increase the value. The MaxLocksPerFile value is saved as part of the following key:
Go to the top of the page
 
+
John Vinson
post Apr 3 2012, 02:32 PM
Post #5

UtterAccess VIP
Posts: 2,550
From: Parma, Idaho, US



Well DON'T edit the registry! That would be swatting flies with a sledgehammer.

I suspect that this database has been subject to many rounds of tweaking, right? Have you Compacted and Repaired it? If so, or if that doesn't help, try creating a new, empty database and Importing everything from this one (to get a clean set of system tables).
Go to the top of the page
 
+
doctor9
post Apr 3 2012, 04:23 PM
Post #6

UtterAccess VIP
Posts: 9,304
From: Wisconsin



QUOTE (Ironangel @ Apr 3 2012, 01:45 PM) *
So what you are saying is that each field should have Yes(Duplicates OK) . . My primary key is based on the social security number.

Ironangel,

No, what I'm saying is that you should LOOK at your table's fields, and LIST them here in a post. If any of the fields have Indexing, make a note next to that field's name, as I did in my example.

In other words: Don't Change Anything Yet. Show us what you currently have, so we can better help you with specific instructions.

Dennis
Go to the top of the page
 
+
doctor9
post Apr 3 2012, 04:30 PM
Post #7

UtterAccess VIP
Posts: 9,304
From: Wisconsin



QUOTE (John Vinson @ Apr 3 2012, 02:32 PM) *
Well DON'T edit the registry! That would be swatting flies with a sledgehammer.

Well said, John.

This is a very good example of a really BADLY written error message.

Ironangel,

In the world of databases, you should NEVER have a table with more than a couple dozen fields, AT MOST. Any more than that, and your table design IS the problem, not the Windows registry. Just list the fields in your table (including any indexing), and we'll go from there.

As I've said many times over the years, the table structure of a database is like the foundation to a house. If the tables aren't set up well, the rest of the database will have problems. If the table design is sound, everything else should fall into place without too much fuss.

Dennis
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Go to Top  ·  Lo-Fi Version Time is now: 25th May 2013 - 06:47 PM