K
Klic
I run the following query
The data structure is
Parent Table: Client PK=AccountNumber (Required, duplicates not allowed)
Child Table: ContractHeader Compound PK=AccountNumber, ContractNumber
If I add a Client record then I can modify using the following SQL (from ADO
connection.Execute)
UPDATE Client SET AccountNumber = 1, ClientName = 'TestName', Address1 =
'a1', Address2 = 'a2', Address3 = 'a3', ContactNumber = '734253' WHERE
AccountNumber = 1
But when the Client has an associated ContractHeader the query gives the
following message
"The record cannot be deleted or changed because table 'ContractHeader'
includes related records."
from SQL view using the same query I get the following error
"Microsoft Access can't update all the records in the update query.
<snip>... 1 record(s) due to key violations...<snip>"
Help / ideas would be appreciated
regards,
Keith
Access 2000.
The data structure is
Parent Table: Client PK=AccountNumber (Required, duplicates not allowed)
Child Table: ContractHeader Compound PK=AccountNumber, ContractNumber
If I add a Client record then I can modify using the following SQL (from ADO
connection.Execute)
UPDATE Client SET AccountNumber = 1, ClientName = 'TestName', Address1 =
'a1', Address2 = 'a2', Address3 = 'a3', ContactNumber = '734253' WHERE
AccountNumber = 1
But when the Client has an associated ContractHeader the query gives the
following message
"The record cannot be deleted or changed because table 'ContractHeader'
includes related records."
from SQL view using the same query I get the following error
"Microsoft Access can't update all the records in the update query.
<snip>... 1 record(s) due to key violations...<snip>"
Help / ideas would be appreciated
regards,
Keith
Access 2000.