Database knowledge Summary

Source: Internet
Author: User

In the follow-up study of VB, we continue to learn about the database content. A database is a collection of data stored on the computer storage medium according to a certain organizational structure. Database technology is to study how to scientifically organize, store, and efficiently obtain and process data. Simply put, a database is like a granary for storing food (comparing data to food). What we need to do is to efficiently distribute and process these foods. The following describes some of my knowledge and questions about database learning.

1. Create an ADO reference? What is ado?
ADO (ActiveX Data Object) is a data access interface. To use an ADO object in Visual Basic, you must add a reference to the ADO object in the project. In Visual Basic, two types of ADO libraries are provided: ADODB and adodr. ADODB is fully functional and contains the main ADO objects, which are included in the dynamic link library msado15.dll. To reference ADODB, select Microsoft ActiveX Data objexts 2.5 library in the project-reference-available reference list. The five examples of databases and the ADO referenced in the examples are ADODB. The other is adodr. You may want to know that adodr is a subset of ADODB. That is to say, it does not have the powerful functions of ADODB. adodr mainly provides operations on the record set, designed for low system requirements and ADO functional requirements. If you want to reference adodr, select Microsoft
ActiveX Data objexts recordset 2.8 library. (Only for your understanding ). Why do we need to create ADO references after talking about this? As a data access interface, ADO can be used to access databases. Visual Basic itself cannot directly access the database, so it is necessary to use ADO to access. Therefore, creating an ADO reference is equivalent to creating a bridge for each other's connections.
Ii. use ADO in instance 2 to access the data source. What is the data source?

For the understanding of the data source, I think of the data source as a winding path. Although you can use ADO to directly access the database, you can create a data source based on the database and access the data source through ADO to obtain the database information. This is also a way to access the database, it is similar to the principle that "a great deal of roads can communicate with Rome. On the ODBC data source Manager interface, we created mostly user DSN. What is "User DSN"? The ODBC Data Source stores information on how to connect to a specified data provider. The user data source is only visible to the current user and can only be applied on the local machine. For "system DSN", the system data source is visible to all users on the current machine. File DSN can be shared by users who have installed the same driver (for your understanding only ).

3. Is the database or data source bound to access data through data binding?

When we bind data through the control, the attribute settings connect to the database. Is the data bound to a data source or database? Data Binding is to associate a control with a specific field of a data source (usually a record set). The data control itself cannot display database data. By setting some properties of the Data Control, link the specified database file, and then display the field content through a data-aware control such as a text box or a label box. In another way, we can understand that, in fact, data binding is to connect the control to the database to obtain the data source, and then bind it to the data source, and present it through the corresponding control. Therefore, data binding only connects controls to databases to obtain data sources.

All of the above are the most basic and easy to understand in database learning. We believe that with these basic support, you can learn your database. It is with basic support that our knowledge is more robust and profound.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.