[MyBatis Source Code Analysis] Processing flow of insert method, update method and delete method (next part)
New Statement Handler Analysis of Configuration
SimpleExecutor's doUpdate method has been analyzed above:
1 public int doUpdate(MappedStatement ms, Object parameter) throws SQLException {
2 Statement stmt = null;
3 try {
4 Configuration configuration = ms.getConfiguration();
5 StatementHandler handler = configuration.n ...
Posted by xylex on Mon, 24 Jun 2019 13:16:40 -0700
Perform update query operation through PreparedStatement
PreparedStatement is a sub-interface of Statement, and its name shows that it is a "ready" Statement, so it represents a pre-compiled SQL statement; the object to obtain it can be obtained by the preparedStatement (String sql) method in Connection, where the parameters are SQL statements with placeholders, so it is in it. Some setXxx( ...
Posted by lafflin on Sun, 23 Jun 2019 10:24:11 -0700
JDBC (1) - Connect to database
I. Introduction:
1.JDBC (Java Database Connectivity) is a general SQL database access and operation independent of a specific database management system.
* Common interfaces (a set of API s)
* A standard java class library for accessing database is defined. Using this class library, database resources can be accessed conveniently in a stand ...
Posted by the_last_tamurai on Mon, 17 Jun 2019 11:26:57 -0700
Spring integrates multiple data sources for dynamic switching
In practical projects, it is often necessary to connect multiple databases, and different business needs often need to access different databases in the implementation process.
jdbc.properties configuration file, configuring multiple dataSource s
##########################MySQL#####################################
hibernate.dialect=org.hiberna ...
Posted by zenag on Fri, 14 Jun 2019 09:53:59 -0700
Isolation Level of JDBC Transactions
I. Isolation Level of Transactions
Multiple transactions run simultaneously in the database. When they access the same data in the database, if the isolation mechanism is not adopted, some concurrency problems will occur. There are several concurrency problems in the database.
(1) Reading "dirty" data refers to the fact that trans ...
Posted by convinceme on Thu, 13 Jun 2019 17:13:06 -0700
Talk about precompiled features of JDBC and Mysql
background
Recently, due to job adjustments, we have been dealing with databases, which has increased many opportunities for close contact with JDBC. In fact, we are using Mybatis.Knowing it, knowing it, is what our engineers and children's shoes should pursue, to help you better understand this technology, and to be more comfortable when facin ...
Posted by davidjwest on Wed, 12 Jun 2019 09:10:54 -0700
PinPoint implements mail alert
PinPoint installation deployment and the pit I encountered
PinPoint collector deploys, configures Tomcat and Dubbo services
PinPoint Use Tutorial
Some pits PinPoint trampled on
HBase and PrinPoint are deployed on different servers
PinPoint implements mail alert
After installing pinpoint, click the settings button in the upper right corne ...
Posted by Jiin on Sun, 09 Jun 2019 13:07:23 -0700
mysql batch import data problems
There is a requirement in the recent project that about 150W data should be imported into the mysql database. There are six tables in total. The tables with the most data have about 100W data.
Because it's a one-time import and isn't used often, it's planned to write a small program that uses native JDBC, jar packages, and runs on the server. ...
Posted by neo926 on Sun, 09 Jun 2019 10:06:42 -0700
[MyBatis Source Analysis] Load the Xml configuration file
Debug Entry
Find the XmlConfigBuilder Test in the mybatis source code and run shouldSuccessfully Load XMLConfigFile () in debug mode.
Initialization
First, create the XMLConfigBuilder object, in the construction method:
Reading files through InputStream to generate Document objects for XML, the operations related to XML are beyond the sc ...
Posted by Imad on Wed, 05 Jun 2019 12:06:24 -0700
Hibernate Introduction Guide
1. When using Hibernate as an orm application, myeclipse is recommended as a development tool.2. Import the corresponding Hibernate jar package into the Lib directory under the Webroot file (webroot - > WEB-INF - > lib)
Notes on jar imports in Hibernate development:(1) Provide a Hibernate jar package download link here, address http://pan ...
Posted by discobean on Sun, 02 Jun 2019 15:30:45 -0700