(I'm a newbie and I'm not grateful if I find any mistakes)
Figure 1: physical database-memory database-control relationship
Tableadapter: communicates with physical databases and memory databases (Dataset), and provides select, update, insert, and delete operations.
Bingdingsource: bind a memory data table (datatable) to the control and provide filter and sort functions for the memory data table (datatable. Note:
1. bindingsource can be used to bind multiple controls to achieve data association between different controls. For example, if you have a able (student ID, name, score, and remarks), bindingsource binds the student ID, name, and score to a dview and binds the remarks to a lable, when you select different students in the datagridview, lable displays the remarks of the corresponding students. (If the datagridview and lable use two different bindingsources, they cannot be linked)
2. The same able can also be bound to different controls through different bindingsources.
In the design view of the XSD file, datatable and tableadapter appear in pairs. 2. There is a data table. Therefore, tableadapter automatically generates a SELECT statement that returns the row value, used to fill the data table. The default value is fill. The getdata method. Tableadapter allows queries with multiple select statements (return row values), select statements (return single values), update statements, delete statements, and insert statements. NOTE: For the SELECT query of each returned row value in tableadapter, its fields must correspond to the fields in the preceding data table.
Figure 2: datatable and tableadapter in the xsd file Visualization