This article was previously published under Q290623
Moderate: Requires basic macro, coding, and interoperability skills.
This article applies only to a Microsoft Access project (.adp).
For a Microsoft Access 2000 version of this article, see 208888.
You may have a need to copy an existing database from Microsoft SQL Server 2000 and to place the database on another computer that is running Microsoft SQL Server 2000 Desktop Engine. This article describes how to do so. The process involves temporarily detaching the database from its server, copying the data file (.mdf) and log file (.ldf) to the target computer, and then attaching the files to the SQL Server 2000 Desktop Engine server there.
NOTE: The previous version of Microsoft SQL Server 2000 Desktop Engine is named Microsoft Data Engine (MSDE).
The following steps demonstrate how to copy the sample pubs database from acomputer that is running SQL Server 2000 and how to place it on a computer that is running SQL Server 2000 Desktop Engine:
On the server that is running SQL Server 2000, open SQL Server Query Analyzer, and type the following line:
On the Query menu, click Execute (or press F5) to run the query. Not that you receive a message that indicates that no records were returned.
NOTE: Temporarily detaching the database from the server allows you to copy the data and log files.
In Windows Explorer, copy Pubs.mdf and Pubs_log.ldf from the Microsoft SQL Server\MSSQL\Data folder on the server to the Microsoft SQL Server\MSSQL\Data folder on the SQL Server 2000 Desktop Engine computer
To attach the files to the SQL Server computer again, run the following statements in the Query Analyzer. Your server's copy of SQL Server may be in a different location than this example; modify the path as needed.