Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Validation Rule Error when appending data to another Access table

Status
Not open for further replies.

rta

MIS
May 1, 2001
13
0
0
US
Hello all:

I have an Excel spreadsheet that I have appended to an Access table-let's call it table 1. In table 1, not all of the fields will contain data. This table will then be appended to a larger table in the database-let's call it main table.

Whenever I try to append, via an "INSERT INTO [tablename].... query, the data that I need from table 1 to the main table, I get a validation rule error. I have researched it and I know that it has something to do with how data is entered. Now, I have made sure that all of the fields in table 1 and the main table have the same fields along with their properties. I still don't understand why I am getting this error. Can anyone please offer me some advice as to how to fix the problem or feed back as to why this error exists whenever I try to append the data? Thank you and appreciate all of the help.

RTA
 
One of the fields in the main table has a data entry rule (aka Validation Rule). Often programmers put these in place to keep people from entering an incorrect value into the table. For example, an orders table that doesn't allow you to ship a negative quantity of an item. The programmer can set access to inspect the quantity field and insure that it is greater than 0. Another common thing is to make sure that users enter data, if they don't produce an error.

The data your trying to import/append to the main table, has a value that breaks a validation rule on the main table. To view the validation rules, you can go into design view and click on the individual field names. Down below you'll see a line called validation rule and that will tell you what rules are in place, then you need to inspect your data to find what's breaking that rule.

If you did not develop this database, ask the person who did, because they can probably tell you right away what rules you're breaking.

HTH Joe Miller
joe.miller@flotech.net
 
Hi Joe,

I have checked each field that I have and their specific validation rule line in table design view, but there's nothing there. My data, which I am appending, is still breaking a validation rule, even though none is visible for the fields I am working with? Please let me know. Thanks.

RTA
Romayne T. Alston
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top