SQL Connection Strings

In the last couple of weeks I have been working a lot with different databases which I had to connect to from Java. It is sometime stressful to look up the right format of the connection string to the database. Even though, these strings should, or are meant to be standardized, they are not.

I found this very helpful website ConnectionStrings.com which lists the connection strings for open-source as well as professional commercial databases. This list includes among others, the connection strings for Microsoft SQL Server 2008, MySQL, Oracle, IBM DB2, Informix, Postgre SQL, Caché, SQLite, …

As an example, if you want to connect to a server in a replicated server configuration without concern on which server to use, use the following connection string:

Server=serverAddress1, serverAddress2, serverAddress3;Database=myDataBase;
Uid=myUsername;Pwd=myPassword;

I want to share this information with you, because it can save you a lot of time, looking up those strings in tutorials or in the documentation of the different databases.

Links:

3 Responses to “SQL Connection Strings”


  1. 1 SQL Tutorials

    Does anyone know if there is another language or set of commands beside SQL for talking with databases?

    I’m working on a project and am doing some research thanks

  2. 2 SQL Tutorials

    You know, the thing about SQL is, that there is virtually nothing that can replace it.

    Does anyone know if a substitute exists for sql? I mean besides MS SQL and Oracle and all that jazz. Thanks.

  3. 3 Marc Giombetti

    Sorry I do not exactly know what you mean? SQL is a database computer language designed for the retrieval and management of data in relational database management systems (RDBMS), database schema creation and modification, and database object access control management.

    MS SQL and Oracle are products or companies selling databases which can be queried by SQL.

    If you are looking for something completely else, there is MDX. Multidimensional Expressions (MDX) is a query language for OLAP databases, much like SQL is a query language for relational databases. It is also a calculation language, with syntax similar to spreadsheet formulas. MDX is mainly used to query OLAP Cubes.

    Hopefully this could help a bit and clear things up.

Leave a Reply