Y
Y
Yuri Denisov2014-05-29 07:51:11
Microsoft
Yuri Denisov, 2014-05-29 07:51:11

Why is SQL Local DB not connecting?

I am writing a program in c#. Let's say I try. I want to use local DB as a local database. It works for me when I start it, those who have visual studio also have it. The rest don't. Error 26, failed to connect. I tried to put SQL Express 2012 LocalDB on my computer, the same garbage. Maybe something else needs to be installed besides it? here is the connection string Data Source=(LocalDB)\v11.0;AttachDbFilename=C:\SOFT\datas.mdf;Integrated Security=True
Tell me what's wrong?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
stringer, 2014-05-29
@denissov

To work with LocalDB, you need NET Framework 4.5 and another library for working with the database. There you need to select the language, click "Load", in the window that opens, check the box next to SqlLocalDB.MSI (the library must be suitable for the Windows x64 \ x86 platform) and click Next (Next ) For loading.

G
gillbeits, 2014-05-29
@gillbeits

As far as I remember from the past, you need to add datas.mdf to the Application Folder and include it without specifying the full path.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question