Questions tagged [mdf]

Master Database File (.MDF) is the starting point of a SQL Server database. It is the primary data file and also points to the other files in the database.

See the Wikipedia article on Microsoft SQL Server.

Related Tags:

429 questions
0
votes
1 answer

Where is my database and App_Data folder?

I have downloaded a project and ran the code and I created an account on my locally running MVC site. I want to delete the database so that it will build a new one; but I can't seem to locate the database. It is supposed to be in App_Data, is it…
user1477388
  • 20,790
  • 32
  • 144
  • 264
0
votes
3 answers

can't insert a record into table

I wrote a program which includes writing and reading from database. When I run the app and try to perform writing I call the following method: public static void AddMessage(string callID, string content) { string select = …
Niko Gamulin
  • 66,025
  • 95
  • 221
  • 286
0
votes
1 answer

MDF file in App_Data, is it thread safe?

I have a local database file (.mdf) in my app_data directory of my C# asp.net mvc program. If I have many user on my site all reading data from the .mdf file is it thread safe? This would be read only, and updated a few times a week. Thanks
Bill
  • 291
  • 3
  • 5
  • 14
0
votes
0 answers

How does the MDF file work?

Let's say I have database with a .MDF file of 100 GB and which is 80% full (80 GB used out of 100 GB available). Within this database I have a table which contributes 40 GB to the .MDF file. My questions are: If I delete 20 GB worth or records will…
Avias
  • 354
  • 1
  • 4
  • 14
0
votes
1 answer

Deploying a project that includes an MDF file to an external computer

Basically, I have a Windows Forms Application that includes a dataGridView with the DataSource being an MDF file named VoRteXData.mdf. Now, I need to deploy this to an external location. For my forms code, it includes: private void…
James Holland
  • 241
  • 1
  • 2
  • 9
0
votes
2 answers

DataGridView From the Web

Basically, I now have my .mdf file for my DataGridView. The contents that the dataGridView loads is within that file. However, if I deploy this software onto another computer, it no longer works despite changing the file location. So, I need to be…
James Holland
  • 241
  • 1
  • 2
  • 9
0
votes
3 answers

incorrect syntax error near ,

I have recently changed my database from access to a .mdf and now I am having problems getting my code to work. One of the problems im having is this error "incorrect syntax near ,". I have tried different ways to try fix this for example putting…
KerrieJMc
  • 15
  • 1
  • 4
0
votes
3 answers

How to read an old SQL Server 2005 mdf file

I've upgraded my SQL Server 2005 to 2008, without backing up the databases. I kept the old data folder with the 2 DB.mdf and DB.ldf files. So how can I import or read my .mdf file into SQL Server 2008 ? If I try to use the 2008 tools import/export,…
0
votes
2 answers

use sql server .mdf file

I am developing a software with vb.net 2010 and sql server 2008 R2. While developing with my laptop where sql server is running every thing is ok, but when I want to deliver the project to the customer I must install sql server R2 to customer…
Hilal Al-Rajhi
  • 437
  • 6
  • 25
  • 49
0
votes
2 answers

Entity Framework object not persisting/saving to database table

I have entity model created in Visual Studio 2010.This is part of my code: Database1Entities1 de = new Database1Entities1(); UserInfo ui = new UserInfo(); ui.Name = "xxx"; ui.Username = "xxx"; ui.Password = "xxx"; de.UserInfoes.AddObject(ui); It…
daidai
  • 531
  • 5
  • 10
  • 22
0
votes
1 answer

Entity Framework Deployment Issues

Entity Framework is new to me i follow the example below to create a wcf service with entity framework. Introduction for Entity Framwork for Beginner It is pretty simply, all the thing was like auto generated, my database was located in my app_data…
Jerry Lam
  • 452
  • 1
  • 7
  • 21
0
votes
2 answers

What version of SQL server do I need when I open a Visual Studio 2010 solution with Visual Studio 2012?

When I open a visual studio 2010 solution with visual studio 2012 I get the following message: SQL Server Express and LocalDB In the Web.config file I changed the connectionstring from: connectionString="Data…
Gilko
  • 2,280
  • 8
  • 36
  • 45
0
votes
3 answers

mdf file is work correctly under App_data folder but after attaching to sql server give following error

mdf file is working correctly under App_data folder but after attaching it to sql server give following error when running asp.net page. Cannot open user default database. Login failed. Login failed for user 'Domain\myUserName'. [edit] More…
Novice Developer
  • 4,489
  • 11
  • 39
  • 42
0
votes
1 answer

How do I copy a DB from the server to the application's AppData folder?

I've been working on an ASP.NET application accessing a DB in my local machine. Now I want to have this DB in the app's AppData folder instead, so I can easily work on it from within VS SQL instance accessing the mdf file, and easily copy and share…
Shimmy Weitzhandler
  • 101,809
  • 122
  • 424
  • 632
0
votes
2 answers

Copy mdf file and use it in run time

After I copy mdf file (and his log file) I tries to Insert data. I receive the following message: "An attempt to attach an auto-named database for file [fileName].mdf failed. A database with the same name exists, or specified file cannot be opened,…
Alon Ashkenazi
  • 1,223
  • 4
  • 21
  • 29