1. Working with SQL Client:
1.1 NameSpace: System.Data.SqlClient;
1.2 Objects: DataSet dataSet;
SqlConnection conn;
SqlDataAdapter dbAdapter;
1.3 Connection Strings:
1.3.1 Using Windows Authentication Mode of Connectivity:
string conString = "Server=.\\SQLEXPRESS;" +
"DataBase=yourDatabase;" +
"Integrated Security=SSPI;";
1.3.2 Using SQL Server Authentication Mode of Connectivity:
string conString = "Server=.\\SQLEXPRESS;" +
"DataBase=yourDatabase;" +
"Uid=yourUserId;Pwd=yourPassword;";
2. Working with OLEDB:
2.1 NameSpace: System.Data.OleDb;
2.2 Objects: DataSet dataSet;
OleDbConnection conn;
OleDbDataAdapter dbAdapter;
2.3 Connection Strings:
2.3.1 Using Windows Authentication Mode of Connectivity:
string conString = "Provider=SQLOLEDB;" +
"Data Source=.\\SQLEXPRESS;" +
"Initial Catalog=yourDataBase;" +
"Integrated Security=SSPI;";
2.3.2 Using SQL Server Authentication Mode of Connectivity:
string conString = "Provider=SQLOLEDB;" +
"Data Source=.\\SQLEXPRESS;" +
"Initial Catalog=yourDataBase;" +
"Uid = yourUserId; Pwd = yourPassword;";
This blogger is recording some code samples,technical skill of java,.Net,javascript, css, html for myself use. All articles are coming from my own experience and my collections which are from internet world. If you find any material have copy right issue please leave a comment to me. I will delete it immediately. These articles are writing in English or Chinese. Hope these information can help other technical guys. Thanks for reading.
Subscribe to:
Post Comments (Atom)
-
1. Change the tile of web.xml from <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "ht...
-
Method 1: import oracle.sql.*; public class JClob { String tableName = null; // String primaryKey = null; // String primaryValue = null; // ...
-
Try to deploy a war package in Tomcat 7 with different web context path, at last it works with below steps: 1. Create context.xml file wi...
No comments:
Post a Comment