IT Nota

  • Home
  • How To
  • .NET
  • WordPress
  • Contact

Linked SQL Server Table Shows #Deleted in MS Access

When linking a SQL Server table (SQL Server 2008 R2) via ODBC, I encountered a major error where all cells in the table display #Deleted when opened from Microsoft Access 2010 (14.0.6123.5001).

Microsoft Access (linked SQL Server table) #Deleted error

The problem turns out to be that Microsoft Jet Database Engine maps bigint datatype to binary. One way to fix this is to clone the table and change the datatype from bigint to either int or (n)varchar. Changing the datatype in the original table just for this purpose is definitely not recommended.

If the table is used only as a reference then the solution is much simpler since it’s not necessary to edit or create new records. Instead of linking the table directly from MS Access, we can create a view that converts the datatype from bigint to a string (nvarchar) and link the view instead.

Create a plain view that selects all fields from the table.

CREATE VIEW dbo.vApplications
AS
SELECT CONVERT(NVARCHAR(25), Id) AS Id
      ,Employee
      ,EmpId
      ,CodeNumber
FROM dbo.Applications;

Then link the view from Access so we can see the data while the original table is untouched.

Microsoft Access (linked SQL Server View) with converted datatype

Further Reading

ACC2000: Linked SQL Server Table That Uses BigInt Data Type as Primary Key Displays #Deleted

August 28, 2013 Filed Under: How To Tagged With: Access, SQL Server

Buy me a coffee?

Buy me a coffee If you find any of the articles or demos helpful, please consider supporting my work here, you'll have my big thanks!

Buy me a coffee Support this site
Buy Me a Coffee?

Categories

  • .NET
  • Coding
  • Cybersecurity
  • Database
  • How To
  • Internet
  • Multimedia
  • Photography
  • Programming
  • Resources
  • Review
  • Tips and Tricks
  • Uncategorized
  • Use Case
  • WordPress
  • Writing

Recent Posts

  • How to View Stored Procedure Code in SQL Server
  • How to Find a String in SQL Server Stored Procedures
  • How to Remove Cached Credentials without Rebooting Windows
  • ESP Work Automation: Empowering Enterprises with Streamlined Workflows and Operational Efficiency
  • How to Search for a String in All Tables in a Database

Recent Posts

  • How to View Stored Procedure Code in SQL Server
  • How to Find a String in SQL Server Stored Procedures
  • How to Remove Cached Credentials without Rebooting Windows
  • ESP Work Automation: Empowering Enterprises with Streamlined Workflows and Operational Efficiency
  • How to Search for a String in All Tables in a Database

Tags

.NET .NET Core AdSense ASP.NET Cdonts Dll Classic ASP Code Editor ETL FSharp Genesis Framework Git Google HP Asset Manager HTML5 Hugo IIS Information Security Internet Internet Information Services iOS JAMStack Linux macOS Microsoft Microsoft SQL Server MVC PHP PowerShell Python Simple Mail Transfer Protocol Smtp Server SQL SQL Server SSIS SSMS SSRS Sublime Text Visual Studio Visual Studio Code VPN Windows Windows 8 Windows 10 Windows 2012 Windows Server

Copyright © 2011-2025 IT Nota. All rights reserved. Terms of Use | Privacy Policy | Disclosure