SpringBoot + mybatis multiple data sources
1. Create project
For Eclipse platform, spring tool suite is installed
File - > New - > other - > spring boot - > spring starter project - > select jdk and other information - > Click Web, select Web, click SQL, select JPA, Mybatis, MYSQL, click next, Finish.
2. Document editing
2.1 modify pom.xml
C ...
Posted by shdt on Tue, 17 Dec 2019 15:18:11 -0800
Research on Spring transaction configuration
I. configuration and analysis of spring+mybaits xml in the project
Generally, we will configure in datasource.xml as follows, but the principle and purpose of each configuration item is not so clear. If not clear, there will be a pit in use, so we will explain these configuration items one by one
(1)Configure data sources
<bean id="dataS ...
Posted by Courbois on Tue, 17 Dec 2019 10:26:15 -0800
Under MVC in Java Web
There is a lot of code, skip it and understand that logic is studying code
Introduce
Looking back at the projects in the previous section, the final hierarchy is:
On MVC, we analyze the advantages and disadvantages of MVC design mode, and add Service layer to deal with business logic, but this is not complete. For large projects, the program s ...
Posted by zTagged on Mon, 16 Dec 2019 20:53:49 -0800
Connect database through JDBC and input data into database
First, we need to create an empty examstudent table in the database:
Second, create a student class corresponding to the contents in the table:
package com.atguigu.jdbc;
public class Student {
// Serial number
private int flowId;
// Examination type
private int type;
// ID number
private String idCard;
// Ticket num ...
Posted by flashman on Sun, 15 Dec 2019 08:10:17 -0800
MySQL small practice 1: quickly insert 10 million pieces of data into MySQL database
Today, I saw a blog post on the Internet. The title is: insert 10 million pieces of data into mysql database in 4 minutes. I think it's very interesting, so I record it for myself to learn.MySQL version: mysql-5.7.22-winx64
1. Set the capacity of MySQL database tables
The default capacity of the database table is 4M. If the stored data exceeds ...
Posted by bbauder on Thu, 12 Dec 2019 08:35:08 -0800
Mybatis integrated spring detailed course (suitable for beginners)
Catalog
1. Integration ideas
2. Integrate the required jar package
3. Steps of integration
4. Two implementation methods of Dao development
6. Summary of Dao's development
@
Mybatis integration of spring is actually the integration of SM in SSM framework.
1. Integration ideas
The id ...
Posted by shakuni on Thu, 12 Dec 2019 04:40:54 -0800
Basic usage of Beetl template [variables, cycles, conditions] - Beetl video course
This video makes a list of the blog's home page;
Content introduction: springboot integrates beetlsql; uses for loop, if control statement, virtual property, variable definition, etc
Learn beetl directory together: https://my.oschina.net/u/1590490?tab=newest&catalogId=6214598
Author: GK
Integrate BeetlSql to query database
Introdu ...
Posted by aniket_dj on Mon, 09 Dec 2019 17:27:36 -0800
MyBatis3.x Idea building
MyBatis was apache An open source project of iBatis In 2010, the project was migrated from apache software foundation to google code and renamed MyBatis. Moved to Github in November 2013.
As an excellent orm framework, MyBatis is often compared with Hibernate. As a popular MyBatis, it avoids almost all JDBC code, manual parameter s ...
Posted by johnie on Sun, 08 Dec 2019 19:46:40 -0800
How Mybatis works
Objectives of this paper:
Using the pure Mybatis framework to obtain data;
Clarify the working process of Mybatis.
Create project and run
First, create maven project, and the process will not be repeated. The dependence is as follows:
<dependencies>
<dependency>
<groupId>org.mybatis</groupId>
<artifa ...
Posted by samsolomonraj on Sat, 07 Dec 2019 18:48:51 -0800
Configuration and common problems of jeecg code generator
Take mysql for example:
diver_name=com.mysql.jdbc.Driver
url=jdbc:mysql://192.168.*.*:3306/car?useUnicode=true&characterEncoding=UTF-8&useSSL=false
username=root
password=dp@ssord
database_name=car
jeecg_config.properties
#code_generate_project_path
project_path=D:\\SourceProject\\car
#bussi_package[User defined]
bussi ...
Posted by invinate on Sat, 07 Dec 2019 18:16:37 -0800