Objective
Source code and Invoke demo download: http://www.cnblogs.com/jyk/archive/2008/04/25/1170979.html
Description of the data Access function library for Ado.net 1.1: http://www.cnblogs.com/jyk/category/67121.html
Because of the use of vs2003 development, the data Access function library (hereinafter referred to as: Access Library) has not been able to consider the ado.net2.0. Although ado.net2.0 did not change at the time of the call, the internal structure changed a lot, adding a series of base classes, making it easier to replace the database.
Although the current data Access function library using VS2008 open, to upgrade, and then can be used, but this will not be able to apply the new features of ado.net2.0, and the original inconvenient place can not be modified, so intend this time to upgrade a complete point.
Let's put up a slaughter.
The advantages of a new data access function library:
1, support a variety of databases.
2, to support the SQL statements, stored procedures, stored procedures, parameters, some of these processing (encapsulation), making the call can be more convenient.
3, support the Ado.net affairs.
4, if there is an exception in the run, you can put the exception information, function name and SQL statements into the "error log" inside, so it is convenient for programmers to find errors, on-line use, can also make a record.
5. The default database type and connection string are set inside the webconfig.
<appSettings>
<add key= "DataType" value = "1"/>
</appSettings>
<connectionstrings >
<add name= "connstr" connectionstring= "Data source=.;i Nitial catalog=northwind;integrated security=true "providername= System.Data.SqlClient"/> </
Connectionstrings>
The main purpose is to try to be as convenient as possible at the time of the call!