[SQL Server] Northwind and pubs Sample Databases安装

时间:2024-04-13 20:52:24

SQL Server 2008上安装Northwind和pubs数据库
1. 下载安装文件
    下载地址:http://www.microsoft.com/en-us/download/details.aspx?id=23654
[SQL Server] Northwind and pubs Sample Databases安装
2. 双击已下载文件“SQL2000SampleDb.msi”,弹出框中点击下一步进行安装
[SQL Server] Northwind and pubs Sample Databases安装
3. 文件默认解压到C:\SQL Server 2000 Sample Databases
[SQL Server] Northwind and pubs Sample Databases安装
4. 复制四个文件到数据库安装目录,如

    D:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA下
    NORTHWND.LDF
    NORTHWND.MDF
    PUBS.MDF
    PUBS_LOG.LDF
[SQL Server] Northwind and pubs Sample Databases安装
5. 导入数据库文件
    步骤1:Database上右键,选择Attach…选项
[SQL Server] Northwind and pubs Sample Databases安装
    步骤2:点击Add按钮
[SQL Server] Northwind and pubs Sample Databases安装
    步骤3:依次导入NORTHWND.LDF和PUBS.MDF
[SQL Server] Northwind and pubs Sample Databases安装
    步骤4:确认导入结果
[SQL Server] Northwind and pubs Sample Databases安装
6. 导入完成,进行测试