Solved

When attaching database to MSDE receive error sp_db_attach not found

Posted on 2004-08-17
4
431 Views
Last Modified: 2013-12-25
I don't know why I am getting the error sp_db_attach not found when trying to attach a database to MSDE.  I have done it once in the past without any problems, but it has been a while and I can't seem to find the sample I used to do it. I type in the following at the C:\Prompt
Osql -E
1>EXEC sp_db_attach "dbname", "c:\path\db.mdf", "C:\path\db.ldf"
2> go
This is when I get the sp_db_attach not found.  Know this is a simple problem, but I need immediate help.

0
Comment
Question by:mbart
  • 2
  • 2
4 Comments
 
LVL 15

Accepted Solution

by:
jdlambert1 earned 300 total points
Comment Utility
Try:

Osql -E
1>USE master
2>go
3>EXEC sp_db_attach "dbname", "c:\path\db.mdf", "C:\path\db.ldf"
4> go
0
 

Author Comment

by:mbart
Comment Utility
Found my problem, brain must be on vacation
0
 

Author Comment

by:mbart
Comment Utility
Used your input jdlambert1 but I had to change to sp_Attach_db
0
 
LVL 15

Expert Comment

by:jdlambert1
Comment Utility
My brain is on sabbatical. If my brain sees yours, I'll say hello.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now