ACC2000: How to Simulate AutoLookup with a Stored Procedure in Access Client/Server (239886)
The information in this article applies to:
This article was previously published under Q239886 Advanced: Requires expert coding, interoperability, and multiuser skills.
This article applies only to a Microsoft Access project (.adp).
SUMMARY
AutoLookup (also known as Row Fix-Up) is a process in which Microsoft Access automatically refreshes data from the primary table of a one-to-many relationship in a multiple-table query when the user edits the foreign key field. You can find an example of AutoLookup in the RecordSource property of the Orders form of the sample database Northwind.mdb.
The Microsoft Jet database engine performs AutoLookup automatically as long as the join field from the "one" side is uniquely indexed, and the user is modifying the foreign key field.
However, if you use an Access project (.adp), it is important to note that Microsoft SQL Server and Microsoft Data Engine (MSDE) do not perform AutoLookup when the user modifies the foreign key field in a multiple-table stored procedure.
To approximate the AutoLookup functionality in an Access project, you can use the ResyncCommand property of a form bound to a multiple-table stored procedure. Note that even when you use the ResyncCommand property to simulate AutoLookup, the values from the primary table in the stored procedure is not refreshed until the record is committed. This behavior differs from the update semantics of the Jet database engine, which refreshes values as soon as the foreign key field is modified.
This article demonstrates how to use the ResyncCommand property to simulate AutoLookup when you use a multiple-table stored procedure with a Microsoft Access form.
REFERENCESFor additional information about AutoLookup, click the article number below
to view the article in the Microsoft Knowledge Base:
209672 ACC2000: Example of Row Fix-Up in the Northwind Orders Form
For more information about the ResyncCommand property, click Microsoft Access Help on the Help menu, type resynccommand property in the Office Assistant or the Answer Wizard, and then click Search to view the topic. For more information about the UniqueTable property, click Microsoft Access Help on the Help menu, type uniquetable property in the Office Assistant or the Answer Wizard, and then click Search to view the topic.
Modification Type: | Major | Last Reviewed: | 12/12/2002 |
---|
Keywords: | AccessCS KbClientServer kbdta kbhowto KB239886 |
---|
|