By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,578 Members | 825 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,578 IT Pros & Developers. It's quick & easy.

error when running an append query

P: 72
Hi,
An append query is giving me the following error:

qryPar can't append all the records in the append query
qryPar set 0 field(s) to null due to at type conversion failure, and it did not add 4626 records due to key violations, 0 records to lock violations, and 0 records due to validation rule violations.
Do you run the query....etc?

I could not see where the problem is. Please let me know if you have an answer. Thanks in advance.

Here is the query code:

INSERT INTO tblPolicies ( PolicyNumber, CarrierNumber, Benefit, ClientNumber )
SELECT tblClientPolicies.PolicyNumber, tblClientPolicies.CarrierNumber, tblClientPolicies.BenefitType, tblClientPolicies.ClientNumber
FROM tblClientPolicies;

Thanks in advance.
Jun 1 '07 #1
Share this Question
Share on Google+
3 Replies


Rabbit
Expert Mod 10K+
P: 12,365
Hi,
An append query is giving me the following error:

qryPar can't append all the records in the append query
qryPar set 0 field(s) to null due to at type conversion failure, and it did not add 4626 records due to key violations, 0 records to lock violations, and 0 records due to validation rule violations.
Do you run the query....etc?

I could not see where the problem is. Please let me know if you have an answer. Thanks in advance.

Here is the query code:

INSERT INTO tblPolicies ( PolicyNumber, CarrierNumber, Benefit, ClientNumber )
SELECT tblClientPolicies.PolicyNumber, tblClientPolicies.CarrierNumber, tblClientPolicies.BenefitType, tblClientPolicies.ClientNumber
FROM tblClientPolicies;

Thanks in advance.
I don't see a problem with the code. But the error message is saying that you're appending records who's primary key value already exists in tblPolicies.
Jun 1 '07 #2

P: 72
Carrier number, Policy number and Benefit type are all primary.
Thanks for your reply
Jun 1 '07 #3

Rabbit
Expert Mod 10K+
P: 12,365
Carrier number, Policy number and Benefit type are all primary.
Thanks for your reply
I'm not sure what to make of this, does this mean you no longer need any help?

The only thing you can do at this point is to check your two tables and see if you have duplicate key values. If you do, then the append won't work for those records.
Jun 1 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.