Solved

How to open this database in Sql express?

Posted on 2014-11-08
3
120 Views
Last Modified: 2014-11-09
Hi,
I'm given a sql mdf file and its log file.  I tried to right clicking on the "Database" in Sql Management Studio, selecting attach and selected to add the mdf file from my Drive.  The database and log file shows up in the lower window.  But when I click okay it gives me error.  Attached is a screen shot.  How can I fix this?

Looks like I was denied access to open this database.  Do I get user id or password from person who owns the database to open it?  How is that done?  I usually just restore database backup file.  This is the first time attaching to one.  I didn't know I need to be given access but the sql express is running on my local pc.  the database is on my local drive.  I'm not sure how to setup access for this.

I'm using sql express 2012
0
Comment
Question by:lapucca
  • 2
3 Comments
 

Author Comment

by:lapucca
Comment Utility
Attached is the error message that says I have no access.
sqlErr.txt
0
 
LVL 10

Accepted Solution

by:
HuaMinChen earned 500 total points
Comment Utility
Hi,
Can you try to copy both .mdf and .ldf files into the folder like

C:\Program Files\Microsoft SQL Server\MSSQL11.SS2012EXPR\MSSQL\DATA

and then redo this

Right-click Databases > Attach

again?
0
 

Author Closing Comment

by:lapucca
Comment Utility
Perfect!  That worked!  Thank you.
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

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

771 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

10 Experts available now in Live!

Get 1:1 Help Now