Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 5571
  • Last Modified:

#DELETE in all fields of All rows in linked SQL Server table

Been migrating some Access data to SQL Server lately.   Experienced a previously unencountered experience this morning.

Opened a table in Access that contained #DELETED in every field and every row of a linked SQL Server table.  Went to SQL Server, and all of the data I imported to the table yesterday is there.  Went back to Access, deleted the linked table, performed a Compact and Repair, closed the database, opened the db, relinked the SQL Server table and still have the same problem.

all of the other tables linked to that SQL Server are working correctly, and the one that is experiencing a problem only has about 2000 records.

Any ideas?
0
Dale Fye
Asked:
Dale Fye
  • 3
1 Solution
 
Jim Dettman (Microsoft MVP/ EE MVE)PresidentCommented:
Dale,

Try adding a TimeStamp column to the table.  As for why, take a look at these two MSKB articles:

PRB: Explaining "Record is deleted" error accessing ODBC table
http://support.microsoft.com/kb/172339

"#Deleted" errors with linked ODBC tables
http://support.microsoft.com/kb/128809

which explains why this occurs and things you can do to avoid the problem.

Jim.
0
 
Jim Dettman (Microsoft MVP/ EE MVE)PresidentCommented:
There's also a work around where you can define an index on the Access side if there is no unique index on the SQL side.

Optimizing Microsoft Office Access Applications Linked to SQL Server
http://msdn.microsoft.com/en-us/library/bb188204.aspx

See the section "Adjusting Dynaset Behavior"

Jim.
0
 
Dale FyeAuthor Commented:
Jim,

Thanks.  The table already had a unique ID field that was defined as the primary key, and a timestamp field.

However, after reading the references, I went back to the table design and realized that the ID field was a bigint, not an integer.  I believe that was the problem as the new table using int instead of bigint is working properly.

Dale
0
 
Jim Dettman (Microsoft MVP/ EE MVE)PresidentCommented:
That will do it!

Jim.
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now