Skip to main content

All Questions

Filter by
Sorted by
Tagged with
105 votes
3 answers
216k views

What is the point of "Initial Catalog" in a SQL Server connection string?

Every SQL Server connection string I ever see looks something like this: Data Source=MyLocalSqlServerInstance;Initial Catalog=My Nifty Database; Integrated Security=SSPI; Do I need the Initial ...
Ryan Lundy's user avatar
  • 208k
73 votes
2 answers
117k views

Persist Security Info Property=true and Persist Security Info Property=false

For the properties: Persist Security Info=true and Persist Security Info=false Can you tell me what is the difference between them, and if I don't put it in my connection what will happen? ...
Nourah's user avatar
  • 761
65 votes
18 answers
471k views

How to fix "The ConnectionString property has not been initialized"

When I start my application I get: The ConnectionString property has not been initialized. Web.config: <connectionStrings> <add name="MyDB" connectionString="Data ...
marcgg's user avatar
  • 66.1k
57 votes
4 answers
106k views

Quick ways to test OLE DB Connection String

For debugging purpose I'd like to know ways to test OLE DB connection string quickly. I've found this free software, it works on my machine, tested successfully. Is there a even quicker way to do so,...
Michael Mao's user avatar
54 votes
1 answer
260k views

A network-related or instance-specific error occurred while establishing a connection to SQL Server [closed]

I deployed my asp.net web application on somee.com, whenever I login into this site (ipc.somee.com) it gives me a network related error like: A network-related or instance-specific error occurred ...
Suresh's user avatar
  • 609
50 votes
7 answers
72k views

SQL Express connection string: mdf file location relative to application location

I am using SQL Express databases as part of a unit test project in c#. My databases is located here: ./Databases/MyUnitTestDB.mdf I would like to use a relative path or variable in the app.config ...
Adam Jenkin's user avatar
  • 4,192
26 votes
7 answers
147k views

Connection string - Keyword not supported: 'initial catalog'

I am using Webmatrix.data's Database entity to create a database connection, however it doesnt like my connection string. I am running it from MVC ASP.net. Ive tried changing it to server / database,...
IAmGroot's user avatar
  • 13.8k
23 votes
3 answers
64k views

Connecting to local instance of PostgreSql with JDBC

I have a running local instance of PostgreSql on a linux machine. When I use psql command from the shell I success to log in without any problem. I need to connect to the PostgreSql via the JDBC, but ...
jutky's user avatar
  • 3,955
22 votes
9 answers
75k views

How to change connection string in DataSet.xsd?

I have build my project in C#, I add DataSet.xsd, and connect him to Oracle DataBase in my computer - work Excellent !!!! When I installed on the customer computer (that connect to his Oracle ...
Gold's user avatar
  • 61.9k
19 votes
2 answers
19k views

unable to retrieve metadata for unrecognized element providers

I get a message error whenever I try to add a controller with Entity framework template but I keep getting a error message unable to retrieve metadata for 'path' unrecognized element providers. ...
Mohamed Naguib's user avatar
16 votes
5 answers
13k views

Is there a need to secure connection string in web.config?

So I am using connection strings in my web.config using SQL authentication. Of course people say this could be a vulnerability as you are storing password in plaintext. However, from what I know, ...
Stellar Sword's user avatar
14 votes
4 answers
19k views

Specifying Port With SqlConnectionStringBuilder?

I've ran into a snag. I have a need to specify the port number for my local installation of SQL Server 2008 R2. So far I've tried using the SqlConnectionStringBuilder with the data source set as .\...
David W's user avatar
  • 517
13 votes
4 answers
10k views

winforms connection properties dialog for configuration string

Is there a way to display the connection properties dialog for connection string browsing(for database) in run time? As I want the user to be able to connect to various database using the GUI. The ...
Thunder's user avatar
  • 10.7k
13 votes
3 answers
2k views

What is the best way to centralize and secure connection strings?

What is the best way to centralize and secure the connections strings used by applications? In my environment we have many internal applications. Each application requires one or more connection ...
Stimy's user avatar
  • 1,511
12 votes
4 answers
27k views

Error occurred during the pre-login handshake

Please read in the entirety before marking this as duplicate. In a project that I am debugging I receive a SqlException saying the following: Additional information: A connection was successfully ...
CodeWarrior's user avatar
  • 7,430
12 votes
3 answers
74k views

Sql developer custom connection string

How to use custom connection string in Oracle sql developer to connect? jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP) (HOST=147.22.109.218)(port=1521))(ADDRESS=(PROTOCOL=TCP) (...
user1570345's user avatar
11 votes
3 answers
31k views

How do I solve "Keyword not supported: 'metadata' "?

I can't connect to SQL Server and connection string of my project is: <add name="Teleport_DEVEntities" connectionString="metadata=res://*/Data.Model.AdvertisingModel.csdl|res://*/Data.Model....
Batuhan Avlayan's user avatar
11 votes
3 answers
34k views

OracleConnection.Open is throwing ORA-12541 TNS no listener

So I am connecting to an external server through C#. I just installed Oracle 11g client on my machine from here: http://www.oracle.com/technetwork/database/windows/downloads/index-090165.html (255MB ...
RG-3's user avatar
  • 6,148
11 votes
2 answers
4k views

Entity Framework Core connect to MSSQL database over SSH tunnel

I've seen a lot of posts asking similar questions, but none of which solved the issue I have. My setup is as follows: Remote host with database: reachable on 127.0.0.1:1433 SSH tunneling: L5000 ->...
товіаѕ's user avatar
  • 3,144
10 votes
5 answers
12k views

How can I safely store and access connection string details?

I'm currently working on a ASP.NET MVC web site, and I've come up to a point where I need to integrate a database into the website. Normally I would simply add the appropriate connection string to ...
Mike Bailey's user avatar
  • 12.7k
10 votes
2 answers
4k views

Entity Framework 6 Programmatically Connect to Postgres

I'm working on programmatically establishing a connection to PostgresSQL using Entity Framework 6. I have this class: public class ClearspanDatabaseContext : DbContext with this constructor: public ...
Nick Gilbert's user avatar
  • 4,229
10 votes
3 answers
95k views

How to get SID, Service Name and Port for Oracle database?

I have oracle database running on address xx.xx.xx.xx I know login, password and initial catalog I am trying to set up new connection in Oracle SQL Developer so I can access this database to take a ...
bobetko's user avatar
  • 5,138
10 votes
3 answers
1k views

Can't connect to SQL LocalDB from Windows Service, WPF app & SSMS work fine?

Having some trouble with a system I'm developing. The layout as far as this question is concerned is a WiX built msi installer which installs SQL LocalDB 2012, a WPF app, and a Windows Service. Both ...
hcp's user avatar
  • 486
9 votes
3 answers
5k views

How can I get the connection string for an SQL Express database listed in LINQPad?

Is there an easy way to get the connection string of a database listed in the connection window of LINQPad (other than using the object explorer of Visual Studio)?
tuncalik's user avatar
  • 1,134
9 votes
2 answers
110k views

How to fix "'ServerVersion' threw an exception of type 'System.InvalidOperationException'"? [duplicate]

I have got a local SQL Server DB, up and running, and I am trying to connect to it in a seemingly failproof way: new SqlConnection(@"Server=(localdb)\v12.0;Integrated Security=true;Database=MyDBName;...
Yulia V's user avatar
  • 3,549
8 votes
2 answers
64k views

ConfigurationManager.ConnectionStrings.ConnectionString Issue

I am trying to pull in data from a Microsoft Access database file, in order to populate several textboxes. (The textboxes are all done in XAML.) I'm quite sure I'm missing something, because the ...
Samuel Brockmann's user avatar
7 votes
1 answer
14k views

Set DSN encoding for ODBC Driver 11 for SQL Server on Windows 10

TL;TR How force this ODBC driver to encode in UTF-8? Detailed description I'm writing PHP 5. 5. application which connects to database Microsoft SQL Server 2014 via PDO using ODBC driver. More ...
Daniel.P.'s user avatar
  • 480
7 votes
0 answers
2k views

I can't make the sqljdbc work with AD username/password

I need to connect to High Availability (HA) / Desaster Recovery (DR), also known as HADR, enabled SQL server 2012 using AD account from Java on Linux. integratedSecurity is not an option since it ...
Hurda's user avatar
  • 4,695
6 votes
2 answers
42k views

Reading from the stream has failed - MySqlException

I'm trying to open a connection to a MySql database using the following code piece: string connectionString = "Server=ip_number;Database=database_name;Uid=uid;Password=password"; MySqlConnection ...
xkcd's user avatar
  • 2,590
6 votes
4 answers
23k views

The configuration section 'connectionStrings' cannot be read because it is missing a section declaration

I am trying to move my webpage(c#) to ISS 7.5 server. I have read that i need to put the in WEBCONFIG to achieve the conection with sql server 2008. I already did that. Here is my WEBCONFIG <?...
funkeeiads's user avatar
5 votes
2 answers
7k views

LINQPad - Connection String to my Oracle DB

I just started using LINQPad and all works great when connecting to my SQL Server DB, but now I'm trying to set up a second connection to my Oracle DB and I'm getting stuck as to how to do it. I ...
John Bustos's user avatar
  • 19.3k
5 votes
2 answers
14k views

Connection string for default instance like for named instance

In my .NET application I am connecting to Microsoft SQL Server 2005 or 2008 database. User selects instance which the application shows it and then application should do something with this instance. ...
Alex's user avatar
  • 1,357
5 votes
4 answers
2k views

Java newbie needs help in database connection

I'm new to Java and even newer to java database connections. I've managed to create a database connection and query a table when I put it in the Main class. Now that I've moved it into a new class ...
iamjonesy's user avatar
  • 25k
5 votes
6 answers
687 views

Why do we need connection strings?

When we connect to a database in ASP.NET you must specify the appropriate connection string. However most other instances where data is to be specified is done within an object. For example why ...
m.edmondson's user avatar
  • 30.7k
5 votes
1 answer
3k views

where to store database string connection in java web app?

I'm about to begin my first project with java Let me tell how I used to handle these things... So far now, I've been workin on asp with a com+ componente made with VB6. The component is registered ...
opensas's user avatar
  • 62.2k
5 votes
3 answers
7k views

Change Connection String at Runtime in EF 6

I mostly use my dbcontext with using statements like this: using (var context = new MyContext()) { } But I later had to add a project with a function to change the database. I found out that I could ...
A.Ima's user avatar
  • 266
5 votes
4 answers
19k views

SQL Express connection string hell ASP.Net

SQL Express 2005 is running locally. I have a project written by another person running on the same machine. All I want to do is connect to it, can't be that hard right? This is the one I use in my ...
Pete Duncanson's user avatar
4 votes
3 answers
21k views

Two hosts in jdbc url

We are using jdbc url like jdbc:mysql://localhost:3306/mysql. How could I set second mysql host in this url? If this is imposible, how could I set in my java application (hibernate) connection to ...
Dedyshka's user avatar
  • 471
4 votes
2 answers
6k views

Get Connection String Without Password Value in C#

I try create method for get the connection string value but without value for password, or show password like * character. I need used it in logging. I use ConnectionStringBuilder for Oracle, ...
Kiquenet's user avatar
  • 14.8k
4 votes
5 answers
10k views

How do I connect to SQL Server with VB?

I'm trying to connect to a SQL server from VB. The SQL server is across the network uses my windows login for authentication. I can access the server using the following python code: import odbc ...
Wayne Werner's user avatar
4 votes
6 answers
19k views

pyodbc connection string sql server authentication

I know this question has been asked many times on the web resulting in many different solutions none which have worked for me. For my scenario I'm attempting to do a simple connection to a MS Sql ...
Marquis Blount's user avatar
4 votes
2 answers
7k views

ibmda 400.1 provider is not registered in local machhine

I am trying to connect to AS400 database from c#.net. Am getting this exception "ibmda400.1 provider is not registered in local machhine", How to resolve this ? This is my connection string and am ...
PRK's user avatar
  • 177
4 votes
1 answer
39k views

Connection string for a remote SQL server

I am trying to connect to a remote SQL server. I would like to know the proper way to connect to the server. TCP/IP protocol is enabled. I am trying this way: @"Server=myserver.com\SQLEXPRESS; ...
Laziale's user avatar
  • 8,175
4 votes
1 answer
3k views

How to define a connection string to create local database in the current folder?

My current connection string is: <connectionStrings> <add name="myConnectionString" connectionString="Data Source=(LocalDB)\v11.0;Initial Catalog=CapacityDatabase.mdf;...
Mihai Bratulescu's user avatar
4 votes
1 answer
4k views

Python Connect to Oracle DB

I currently use PYODBC to connect to MS SQL Server and MYSQL, but now need to access an Oracle database as well. I have Oracle SQL Developer installed on my work comp (but there doesn't seem to be ...
user1893148's user avatar
  • 2,150
4 votes
1 answer
4k views

Changing ASP.NET Website Administration Tool Connection String

I've created user roles with Asp.net website administration tool. I want to store these user roles in my table which are stored in SQL server. But the tool has created default connection string and ...
Umut Koseali's user avatar
4 votes
2 answers
5k views

CREATE DATABASE permission denied in database 'master'. error in MVC 4 application

After deploying my MVC 4 application, I try to register user, get such error: CREATE DATABASE permission denied in database 'master'. Connection string is : <add name="Market" providerName="...
user avatar
4 votes
0 answers
1k views

Service throws "The underlying provider failed on Open" error randomly

I have a singular issue with my Entity Framework code. I have a service; very night, it makes some update operations on my database. Sometimes, it seems almost randomly, it return the error: The ...
Piero Alberto's user avatar
4 votes
1 answer
3k views

Location of Microsoft access database for windows form when creating setup file using installshield

I have developed windows form which uses Microsoft Access Database. During development i have put database file in root folder with in project. When i run application through visual studio, it run ...
Amrit Sharma's user avatar
  • 1,906
3 votes
2 answers
12k views

Storing Password in SSIS Package

I have an SSIS Package which is used to connect Oracle. I used the Oracle Provider for OLEDB connection manager in SSIS. I have specified my server name, user name and password, selected the check ...
techspider's user avatar
  • 3,420

1
2 3 4 5
9