常用的数据库链接串
<!--
Access 2007: Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\myFolder\myAccess2007file.accdb;Persist Security Info=False;
Access 2000: Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\mydatabase.mdb;User Id=admin;Password=;
-->
<add name="Access" connectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|\myDatabase.mdb;User Id=admin;Password=;" />
<!--SQL Server 数据库连接方式
SQL Server 2008: Provider=SQLNCLI10;Server=myServerAddress;Database=myDataBase;Uid=myUsername; Pwd=myPassword;
SQL Server 2005: Provider=SQLNCLI;Server=myServerAddress;Database=myDataBase;Uid=myUsername; Pwd=myPassword;
SQL Server 2000: Provider=SQLOLEDB;Data Source=myservername;Initial Catalog=mydemodb;User Id=myusername;Password=mypasswd;
Trusted : Provider=SQLOLEDB;Data Source=myservername;Initial Catalog=mydemodb;Integrated Security=SSPI;
-->
<add name="SqlServer" connectionString="Provider=SQLOLEDB;Data Source=myservername;Initial Catalog=mydemodb;User Id=myusername;Password=mypasswd; " />
<!-- Oracle数据库连接方式
ms Provider : Provider=msdaora;Data Source=MyOracleDB;User Id=myUsername;Password=myPassword;
Oracle Provider: Provider=OraOLEDB.Oracle;Data Source=MyOracleDB;User Id=myUsername;Password=myPassword;
-->
<add name="Oracle" connectionString="Provider=OraOLEDB.Oracle;Data Source=Db.X.Com;User ID=UID;Password=PWD" />
<!--DB2数据库连接方式
APPC 方式 : Provider=DB2OLEDB;APPC Local LU Alias=MyAlias;APPC Remote LU Alias=MyRemote;Initial Catalog=MyCtlg;Package Collection=MyPkgCol;Default Schema=Schema;User ID=myUsername;Password=myPassword;
IBM Provider: Provider=IBMDADB2;Database=myDataBase;Hostname=myServerAddress;Protocol=TCPIP; Port=50000;Uid=myUsername;Pwd=myPassword;
-->
Access 2007: Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\myFolder\myAccess2007file.accdb;Persist Security Info=False;
Access 2000: Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\mydatabase.mdb;User Id=admin;Password=;
-->
<add name="Access" connectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|\myDatabase.mdb;User Id=admin;Password=;" />
<!--SQL Server 数据库连接方式
SQL Server 2008: Provider=SQLNCLI10;Server=myServerAddress;Database=myDataBase;Uid=myUsername; Pwd=myPassword;
SQL Server 2005: Provider=SQLNCLI;Server=myServerAddress;Database=myDataBase;Uid=myUsername; Pwd=myPassword;
SQL Server 2000: Provider=SQLOLEDB;Data Source=myservername;Initial Catalog=mydemodb;User Id=myusername;Password=mypasswd;
Trusted : Provider=SQLOLEDB;Data Source=myservername;Initial Catalog=mydemodb;Integrated Security=SSPI;
-->
<add name="SqlServer" connectionString="Provider=SQLOLEDB;Data Source=myservername;Initial Catalog=mydemodb;User Id=myusername;Password=mypasswd; " />
<!-- Oracle数据库连接方式
ms Provider : Provider=msdaora;Data Source=MyOracleDB;User Id=myUsername;Password=myPassword;
Oracle Provider: Provider=OraOLEDB.Oracle;Data Source=MyOracleDB;User Id=myUsername;Password=myPassword;
-->
<add name="Oracle" connectionString="Provider=OraOLEDB.Oracle;Data Source=Db.X.Com;User ID=UID;Password=PWD" />
<!--DB2数据库连接方式
APPC 方式 : Provider=DB2OLEDB;APPC Local LU Alias=MyAlias;APPC Remote LU Alias=MyRemote;Initial Catalog=MyCtlg;Package Collection=MyPkgCol;Default Schema=Schema;User ID=myUsername;Password=myPassword;
IBM Provider: Provider=IBMDADB2;Database=myDataBase;Hostname=myServerAddress;Protocol=TCPIP; Port=50000;Uid=myUsername;Pwd=myPassword;
-->
关于作者:
王昕(QQ:475660)
在广州工作生活30余年。十多年开发经验,在Java、即时通讯、NoSQL、BPM、大数据等领域较有经验。
目前维护的开源产品:https://gitee.com/475660
目前维护的开源产品:https://gitee.com/475660