[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

#Deleted Problem with MS Access and MS SQL

Posted on 2013-05-10
5
Medium Priority
?
428 Views
Last Modified: 2013-11-20
Hello Experts,

I'm using MS Access 2000 as my front end and MS SQL Server as the backend (I believe it is 2008 R2).

I have a table with 3 million record that is giving me trouble.  At least part of the table has become currupt and the prhase #Deleted now appears in every field of a specific row.

The problem record can be displayed if I run this query:
SELECT CompPricing.Manufacturer, CompPricing.*
FROM CompPricing
WHERE (((CompPricing.Manufacturer) Like "*hHQp*"));

However, when the query results appear the work #Deleted appears in every field.

If I attempt to delete the row from the query, the system acts as it would if I were actually deleting a row, except that no deletion ever takes place.

I'm using ODBC to connect to the MS SQL Server.

I logged into the MS SQL server and attempted to manually delete the record.
As before, the system responded as it would if the record was deleted,
although no deletion took place.

The deleted record is causing other routines to fail so I can not ignore it .

Please HELP!

Thank you
0
Comment
Question by:pcalabria
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 58
ID: 39155499
<<I have a table with 3 million record that is giving me trouble.  At least part of the table has become currupt and the prhase #Deleted now appears in every field of a specific row.>>

 #Deleted does not mean the table is corrupt.

 #Deleted is used by JET to indicate that it can no longer find the row.

 This can be caused by numerious things.

 First, add a timestamp column to the table, whcih turns on row versioning and then re-link the table in Access.  That takes care of it in most cases.

 If not, we'll need to look at a little more in detail.

Jim.
0
 
LVL 6

Expert Comment

by:BurundiLapp
ID: 39155500
Have any triggers been added to the affected tables recently?  It could be a badly coded trigger at fault here.
0
 

Author Comment

by:pcalabria
ID: 39156518
Jim,

I'm not sure what a timestamp column is.  What data goes in the column?  No triggers.
0
 

Author Comment

by:pcalabria
ID: 39156702
I figured out what a timestamp is, but it turns out I have had one all along.

I deleted the link to the table, then recreated it, and have the same problem.

I also deleted the ODBC connect and reconnected... same prolem.

Any iteas?
0
 
LVL 58

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 1500 total points
ID: 39158007
<<If I attempt to delete the row from the query, the system acts as it would if I were actually deleting a row, except that no deletion ever takes place.>>

 This and #Deleted are usually indications that a unique index is not available or that the key that the record is based on is being changed by a trigger.

  To understand how JET works with ODBC datasources and why #Deleted can occur, have a read through this:

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

there is also a slightly updated version of that here:

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

also, since this is Access 2000, it may be a result of this:

ACC2000: Linked SQL Server Table That Uses BigInt Data Type as Primary Key Displays #Deleted
http://support.microsoft.com/kb/321901

 Take a read through those and see if anything might pertain.  Also, I'd check if your up to date on service packs.

  There is one other problem that used to exist with JET 4.0, but that would give you #Deleted in every other row.  Once again however, it relates to the primary key being used and how JET works with it's ODBC keyset cursors.

Jim.
0

Featured Post

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question