Join query in sql99 syntax
SELECT query list FROM table 1 alias [connection type] JOIN table 2 alias ON connection conditions [WHERE filter criteria] [GROUP BY] [HAVING filter criteria] [ORDER BY sort list]
inner connection: inner External connection: Left outer: left [outer] Right outer: right [outer] full ...
Posted by kampbell411 on Sun, 20 Feb 2022 14:24:25 +0100
In the process of project development, when some data is written, if it already exists, it can be overwritten. This can prevent multiple repeated writes to the only key conflict and error reporting. Here are two examples of using saveOrUpdate in MyBatis configuration files
<!-- Single data saving -->
<insert id="saveO ...
Posted by mckooter on Sun, 20 Feb 2022 09:29:36 +0100
1, MHA concept
MHA (MasterHigh Availability) is a set of excellent software for failover and master-slave replication in MySQL high availability environment.The emergence of MHA is to solve the problem of MySQL single point.During MySQL failover, MHA can automatically complete the failover operation within 0-30 seconds.MHA can e ...
Posted by ruano84 on Sun, 20 Feb 2022 09:08:01 +0100
The commodity search function in the mall project has never done real-time data synchronization. Recently, it was found that Alibaba's open source canal can synchronize the data in MySQL to Elasticsearch in real time, which can well solve the problem of data synchronization. Today, let's talk about the use of canal, hoping to help ...
Posted by sunil.23413 on Sun, 20 Feb 2022 05:54:30 +0100
1. Group query
group by ， generally used in conjunction with aggregate functions, the found data is meaningful *Fields to query: 1. Grouping field itself 2. Aggregate function
-- For example, I group by part number. For example, there are three departments, and then I calculate the average salary of each department. There should be thre ...
Posted by scottd on Sun, 20 Feb 2022 03:26:58 +0100
Level 1: specify the type of JDBC encapsulation
This task: encapsulate a JDBC tool class as required.
In order to complete this task, you need to master the basic use of JDBC. Please refer to the previous training content Advanced features of Java - JDBC (Part 1).
This chapter will encapsulate ...
Posted by revdev on Sun, 20 Feb 2022 03:10:29 +0100
Previously, I learned that the integration of single data source and multiple data sources of springboot + mybatis has been used. In this article, let's talk about the high-end usage of mybatis
1. Environmental collocation
1.1 pom dependency
Based on springboot 2.5.6, you can also refer to the first article of mybatis
<!--Mysql Dependent ...
Posted by sella2009 on Sun, 20 Feb 2022 01:32:08 +0100
1. Concept of lock
Lock mechanism: a rule designed by a database to ensure the consistency of data and use various shared resources to become orderly when accessed concurrently. For example, when purchasing goods on e-commerce websites, there is only one commodity in the commodity table, and at this time, two people buy at the sa ...
Posted by faifas on Sun, 20 Feb 2022 00:21:44 +0100
MySQL is generally installed in three ways: binary version, compiled version and RPM package. The more common is the binary version installation, which is convenient and simple. Compared with the compilation and installation, if it does not pursue the ultimate performance, it is not very different in use. This tutorial takes the binary ...
Posted by sharal on Sat, 19 Feb 2022 20:35:32 +0100