Import Key Violations fixed with compact and repair

  • Thread starter The Joker via AccessMonster.com
  • Start date
T

The Joker via AccessMonster.com

Hello everyone!

I have an import (from a button) in a database. The database has many users.
Every so often the import button will stop working and throw a key violations
error. I then kick everyone out of the database and run compact and repair,
then there are no issues. It seems to be happening more often though and
getting everyone out of the database to keep fixing this is becoming a pain.
I'm using Access 2007. Is this a known error of sorts or is there something
I can do to prevent this? Thank you!!
 
O

orange via AccessMonster.com

The said:
Hello everyone!

I have an import (from a button) in a database. The database has many users.
Every so often the import button will stop working and throw a key violations
error. I then kick everyone out of the database and run compact and repair,
then there are no issues. It seems to be happening more often though and
getting everyone out of the database to keep fixing this is becoming a pain.
I'm using Access 2007. Is this a known error of sorts or is there something
I can do to prevent this? Thank you!!
What is the exact error message? Did you look it up in Access Help? Google?
 
G

Gina Whipp

The Joker,

Key violation errors usually mean that you are trying to import data to a
field that cannot except that particular data. You should have a table with
Errors in it to tellyou which field(s) are the issue. An example would be,
you have a field to accept A, B or C but you try to import a value of D...
that will throw up a Key Violation and should create an Error table.

You need to check for that error table and see where the issue lies.

--
Gina Whipp
2010 Microsoft MVP (Access)

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

Hello everyone!

I have an import (from a button) in a database. The database has many
users.
Every so often the import button will stop working and throw a key
violations
error. I then kick everyone out of the database and run compact and repair,
then there are no issues. It seems to be happening more often though and
getting everyone out of the database to keep fixing this is becoming a pain.
I'm using Access 2007. Is this a known error of sorts or is there something
I can do to prevent this? Thank you!!
 
T

The Joker via AccessMonster.com

Thanks for the responses!

I don't believe it's a legit error. I understand what a key violation is,
and there shouldn't be one. Everytime I compact and repair the database all
is fine for a while. Then it will start throwing that error again and all I
have to do to fix it is to compact and repair again. It will even work on
certain computers with no issue and others will throw the error.

Any other thoughts or suggestions would be greatly appreciated. Thanks!!
 
G

Gina Whipp

The Joker,

It could, <gulp>, early signs of corruption, have a look at...

http://www.granite.ab.ca/access/corruption/symptoms.htm

--
Gina Whipp
2010 Microsoft MVP (Access)

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

Thanks for the responses!

I don't believe it's a legit error. I understand what a key violation is,
and there shouldn't be one. Everytime I compact and repair the database all
is fine for a while. Then it will start throwing that error again and all I
have to do to fix it is to compact and repair again. It will even work on
certain computers with no issue and others will throw the error.

Any other thoughts or suggestions would be greatly appreciated. Thanks!!
 
T

The Joker via AccessMonster.com

Thank you very much! That is what I feared :-(

I've created a new database and I'm going to re-import everything from the
old database. Hopefully this will fix the issue (at least temporarily, I'm
looking into APEX now).
 
G

Gina Whipp

Glad to help...

On tips to prevent corruption, have a look at...

http://allenbrowne.com/ser-25.html

Good Luck!
Gina Whipp
2010 Microsoft MVP (Access)

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

Thank you very much! That is what I feared :-(

I've created a new database and I'm going to re-import everything from the
old database. Hopefully this will fix the issue (at least temporarily, I'm
looking into APEX now).
 

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

Top