Article ID: 251289 - View products that this article applies to.
This article was previously published under Q251289
This article has been archived. It is offered "as is" and will no longer be updated.
Moderate: Requires basic macro, coding, and interoperability skills.
This article applies only to a Microsoft Access database (.mdb).
When you add a new record to a linked Microsoft SQL Server table and then move to a different record, you may notice one of the following symptoms:
When you press the TAB key to move to the next new record after entering any part of a new record in a table, the record you just typed disappears.When you type a complete new record in a table and then move to an existing record, the record you typed disappears.When you type only part of a new record into a table and then move off that record to an existing record, your new record disappears, and the last record in the table appears to be duplicated.When you type any part of a record in a form, and then leave the record, the information you type disappears.IMPORTANT: Data is not actually lost. Do not try to add the record again; it does exist. Do not try to delete the apparent duplicate record. By deleting it, you delete the original record, which appears to be duplicated, not the record you just added.
If the SQL Server table has an identity column, when you try to add a record, you instead see what appears to be a duplicate of the previous record. The new record does not display the correct data until you refresh the recordset. This behavior is related to the way Microsoft Access requeries the SQL Server database.
To resolve this issue, obtain the latest Microsoft Jet 4.0 service pack update. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
239114To work around this problem, use any of the following three methods.
(http://support.microsoft.com/kb/239114/ )How To: Obtain the Latest Service Pack for the Microsoft Jet 4.0 Database Engine
Using an Access ProjectYou can use an Access project instead of an Access database. By using an Access project, you do not need to have linked tables to connect to a SQL Server database.
For additional information about converting your Access database to an Access project, click the article numbers below to view the articles in the Microsoft Knowledge Base:
(http://support.microsoft.com/kb/241743/EN-US/ )ACC2000: "Access 2000 Upsizing Tools" White Paper Available in Download Center
(http://support.microsoft.com/kb/250616/EN-US/ )ACC2000: How to Use DTS to Export Data from a Microsoft Access Database to a SQL Server Database
Using Forms in an Access DatabaseIf you see this behavior in a form, use Microsoft Visual Basic for Applications code for the BeforeInsert and AfterInsert events to automatically requery the data and move the form to the newly added record. With the sample code below, you can add to the events to automatically refresh the record on the form.
NOTE: With this method you may notice you have to move off a new record twice. That is, when you add a new record and then press the TAB key or one of the record navigation buttons to add another new record or move to the previous record, you have to press the record navigation button a second time to get to the appropriate record. This does not affect closing the form.
Using Tables in a MDBIf you see this behavior in a table, you can manually resort the table or close and reopen the table.
Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article. This problem was corrected in the latest Microsoft Jet 4.0 service pack.
Steps to Reproduce Behavior
Contact us for more help
Connect with Answer Desk for expert help.