• Sales: 1-800-961-2888
  • Support: 1-800-961-4454

What are some sample Connection Strings from ASP and ASP.NET?


These are sample connection strings for MSSQL Server 2005, MSSQL Server 2008, and MySQL from ASP or ASP.NET.

Contents

//

Important Note

The following details will need to be replaced for each of the following examples with your database details:

  • myServerAddress
  • myDataBase
  • myUsername
  • myPassword

Microsoft SQL 2005 & 2008

SQL Native Client

Driver={SQL Native Client};Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;

SQLNCLI

Provider=SQLNCLI;Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;

SQLOLEDB

Provider=SQLOLEDB;Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;

MySQL

ODBC

Driver={MySQL ODBC 3.51 Driver};Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;OPTION=3






© 2011-2013 Rackspace US, Inc.

Except where otherwise noted, content on this site is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License


See license specifics and DISCLAIMER