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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can't add/modify new row; "Key column information is insufficient..."

Status
Not open for further replies.

nstouffer

Programmer
Jan 11, 2002
52
US
I'm just trying to edit/add a new row and I keep getting
a message stating "Key column information is insufficient or incorrect. Too many rows were affected by update."

This is a table created by and linked to access. I can
modify existing rows but not any I try to add. There are
no relationships set, and i tried with and without indexes.

I tried to make a column a primary key but I've got two
rows 'stuck' with NULLS and it won't let me edit or delete...just gives me that message.

Any ideas....Thanks!
 
I dunno all the possible causes, but whenever I get that error it is because there is no PK. i.e. the PK uniquely identifies each row, and SQL is trying to do an operation but can't determine which row(s) need to be affected. It doesn't want to guess and update the wrong rows, so it gives up and throws an error msg.

So I guess you need a PK. But PKs cannot have NULL values, so you gotta fix those rows somehow. Can they be deleted? Can you maybe copy all the records (except the Null ones) to a temp table, then truncate the original table, or delete all the records, then copy back fro mthe temp table once you've created a PK?
 
Ok, I will try that...can you tell me how to do
an append query in SQL commands. And i will condition
it by a column value to exclude the null rows..

I an access person trying to get more familiar with
straight SQL.

thanks
nathan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top