Breaking News
You are here : Home / Microsoft .net / Connection Strings for ms.net Framework
Connection Strings for Databases

Connection Strings for ms.net Framework

Connection Strings for ms.net Framework

Hello friends ! This is my post on Design Aeon .I think I should post Something Useful. So i am posting microsoft .net connection strings for various databases Like:-Ms Access Connection String, Sql Server Connection Strings, Oracle Connection strings.The mostly used Connection strings are as below:

SQL SERVER CONNECTION STRING

Trusted Connection String Withour user name and password Requirements.

[jbox color=”yellow” radius=”1″] Class Library: System.Data.SqlClient(Declared at the top of the page) [/jbox]
[jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]
Server=ServerAddress; Database=urDataBaseName; Trusted_Connection=True;
[/jbox]

SQL SERVER CONNECTION STRING SECURED

String is same but here user name and password is used.

[jbox color=”yellow” radius=”1″] Class Library: System.Data.SqlClient(Declared at the top of the page) [/jbox] [jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]
Server=ServerAddress; Database=urDataBase; User ID=yourUsername; Password=yourPassword; Trusted_Connection=False;
[/jbox]

[divider]

ORACLE CONNECTION STRING SECURED

[jbox color=”yellow” radius=”1″] Class Library: Oracle.DataAccess.Client.Oracle(Declared at the top of the page) [/jbox]

[jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]Data Source=TORCL;User Id=myUsername;Password=myPassword;[/jbox]

ORACLE CONNECTION STRING Integrated Security

[jbox color=”yellow” radius=”1″] Class Library: Oracle.DataAccess.Client.Oracle(Declared at the top of the page) [/jbox]

[jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]Data Source=TORCL;Integrated Security=SSPI;[/jbox]

[divider]

MS ACCESS CONNECTION STRING

[jbox color=”yellow” radius=”1″] Class Library:System.Data.OleDb(Declared at the top of the page) [/jbox]

[jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]Provider=Microsoft.ACE.OLEDB.12.0; Data Source=C:\myFolder\myAccess2007file.accdb; Persist Security Info=False;[/jbox]

MS ACCESS CONNECTION STRING With Db Password

[jbox color=”yellow” radius=”1″] Class Library:System.Data.OleDb(Declared at the top of the page) [/jbox]

[jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\myFolder\myAccess2007file.accdb;Jet OLEDB:Database Password=MyDbPassword;[/jbox]

[divider]

MYSQL CONNECTION STRING

[jbox color=”yellow” radius=”1″] Class Library:MySql.Data.MySqlClient(Declared at the top of the page) [/jbox]

[jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]

Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;[/jbox]

MYSQL CONNECTION STRING With Port

[jbox color=”yellow” radius=”1″] Class Library:MySql.Data.MySqlClient(Declared at the top of the page) [/jbox]

[jbox color=”blue” radius=”1″ vgradient=”#fdfeff|#bae3ff”]

Server=myServerAddress;Port=1234;Database=myDataBase; Uid=myUsername; Pwd=myPassword;[/jbox]
[divider]

I hope you guys found these Connection Strings Useful.Vote Up, Like and Share if you like.

Tags : , , , , , , ,

Leave a Reply

Want to join the discussion ? Feel Free to contribute !