Click here to Skip to main content
15,889,909 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

I am using SQL Server LocalDB, it is working in my system( I have Visual Studio 2015, SQL Server 2014 ).


But it is not working the production machine where there is no SQL server and Visual studio.


Does the SQL Local DB 2012 works by only installing SQLLocalDB 2012 or need to install any other support files ?

What I have tried:

Installed SQL LOCALDB 2012,

Connection string I used,
@"Data Source=(LocalDB)\v11.0;AttachDbFilename=" + Application.StartupPath + "\\DB\\DB.mdf;Integrated Security=True";

Db files are located wuth Name "DB" in the application folder
Posted
Updated 21-Sep-17 19:19pm

1 solution

 
Share this answer
 
Comments
palraj001 22-Sep-17 1:26am    
Thanks for your reply. In client machine I have installed Local DB , I need my application has to work with the MDF files which is in my application folder. for this we need to install SQL Express ?
Mehdi Gholam 22-Sep-17 1:47am    
No, the localdb install is sufficient.
palraj001 22-Sep-17 2:37am    
Yes. But while access the SQL Connection I am getting following error in a new computer.

A network-related or instance-specific error occurred while establishing a connection to SQL Server. ... Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 – Error locating server/Instance Specified)

I have checked localDB instance , Its running state,

Mehdi Gholam 22-Sep-17 2:43am    
LocalDB is meant to be used for local access (same machine), not network accessible from other machines.
palraj001 22-Sep-17 3:07am    
I installed LocalDB in the Other machine too. I am connecting the DB located in the Same machine not in the network. is there any support file installed to use this SQLLOCALDB feature.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900