Some other large database systems, such as DB2 and SQL Server, occupy the main database market. With the in-depth promotion of IBM, DB2 will have a broader development prospect. This article will introduce you. NET development, some technical comparisons using DB2 are for your reference.
In the view of. NET application software developers, using DB2 is no different from using any other relational database. There are countless examples of using SQL Server and Oracle products to execute database tasks, but there are far fewer documents on using Microsoft technologies including. NET to access DB2 databases.
Currently, developers can use different access technologies to program these methods. NET Client Connected to DB2, these codes are basically the same, but there are still some interesting restrictions that we need to consider.
DB2 Architecture Overview
The basic elements of the DB2 database engine are database objects, System directories, directories, and configuration files. All data is accessed through the SQL interface. We can only run DB2 Univeral DatabaseUDB) as a database server. This does not require other products, but we also need other products for remote clients.
DB2 UDB server components provide support for communication with database servers using TCP/IP, SNA, or IPX/SPX protocols, this allows you to access the remote client of the running management client, Runtime library, or application development client. The Application Development client component is a tool set for database application developers. It includes library files, header files, APIs, and sample code.
We are mainly concerned with the client components that can access the database server through the network. By using DB2 Connect, Our. NET applications can access host-based DB2 systems, such AS DB2 for AS/400, DB2 for OS/390, and DB2 for VSE.
The connection to DB2 determines what we can do. There are three technologies available to connect to DB2 from. NET:
1. Use OleDb. NET Managed Provider. If you are running DB2 V7 or earlier versions and the COM object is called, both Microsoft and IBM recommend that you use the OleDb data provider to access most DB2 data. In. NET Framework, OleDb providers are represented through COM InterOp and use drivers that can be used for ADO development.
2. Use ODBC. NET Managed Provider. This method provides access to the local ODBC driver, which is the same as OLEDb. NET Data Provider provides access to the local OLEDb Provider. ODBC. NET Data Provider is an additional component of the. NET Framework. It can be used with all compatible ODBC drivers.
3. Use IBM DB2. NET Provider β): This method provides support for connecting ADO. NET to DB2 v8.1. DB2. NET Data Provider is an internal plug-in Attachment of Visual Studio. NET Framework. It can access DB-database servers running on different hardware and operating system platforms. It is still in beta testing, but IBM will soon release its official product. DB2. Net Data Provider can connect applications developed using ADO. NET to the following DB2 database server: