The error that you are getting is related to the violation of "PRIMARY KEY"
constraint. To know what primary key is defined on the table run the
following statment.
sp_pkeys <table name>
Make sure that you are inserting non duplicate values in the primary key.
ex:
create table t(idd int primary key)
insert into t values (1)
insert into t values (2)
insert into t values (3)
insert into t values (3) --error
in above case 4th insert into will fail because of duplication of primary
key value.
Re: Allen Brownes Copying forms/Subforms ... Is OrderID the primary key?...Allen Browne - Microsoft MVP. ... perhaps the duplicate is on another field where you specified a "No ... (microsoft.public.access.modulesdaovba)
RE: Duplicate record with child fields ... with the sub table tblWesternBlotWorksheetsub ... record and trying to put it in the primary key of the new record. ... to copy duplicate records with child fields. ...GelNumber is the primary Key in the main table with a 1:N relationship ... (microsoft.public.access.forms)
Re: Duplicate the record in form and subform ... Have changed the code as below but got an error message "Error#3061, ...Dim strSql As String 'SQL statement. ... Dim lngID As String 'Primary key value of the new record. ... 'Make sure there is a record to duplicate.... (microsoft.public.access.formscoding)
replication fail ... When doing a search for "Violation of Primary Key... >Violation of primary key constraint 'PK-measure'. ... (microsoft.public.sqlserver.replication)