One-to-one association mapping for MyBatis

Original link: http://www.yiidian.com/mybatis/one-to-one.html 1 What are one-to-one, one-to-many mappings? Take users and orders for example, One-to-one: An order belongs to only one user==>The order is one-to-one with the user One-to-many: A user can have multiple orders==>A user is one-to-many with an order Note: In MyBatis, if you want ...

Posted by Jak on Sat, 21 Mar 2020 01:45:27 +0100

Simple use of mybatis auto generation interface plug-in

About the use of the mybatis generator plug-in, the main task is to write the configuration file of the plug-in. The database information used in this instance is as follows. The database name is world, including three tables: city, country, and country The structure of the city table is as follows: The country table structu ...

Posted by crusty_php on Fri, 20 Mar 2020 16:49:15 +0100

Detailed explanation of total record optimization of count query in paging component

1 background When using the paging function of mybatis plus (hereinafter referred to as MBP). Found a JsqlParserCountOptimize The official didn't give a detailed introduction to the paging optimization processing class of, and didn't find a few words on the Internet to analyze the logic of this class, which we dare not use. It's also convenient ...

Posted by silas101 on Wed, 18 Mar 2020 08:21:33 +0100

[Chapter 9 of Mybatis source code analysis] SqlSessionHolder function

origin In the process of using mybatispree, it is found that an error will be reported if an insert is executed and a batch insert is executed in a transaction Cannot change the ExecutorType when there is an existing transaction [the external link image transfer failed. The source station may have ant ...

Posted by brij_theinvader on Wed, 26 Feb 2020 05:28:18 +0100

WeChat official account develops SpringBoot +Spring Security + thymeleaf + layui

SpringBoot +Spring Security + thymeleaf + layui Program ideas and resource sources: Wx Java wechat working number original demo NatApp intranet penetration layuimini background template Wechat work number interface test number acquisition This is written for the purpose of binding the WeChat official a ...

Posted by sniperscope on Mon, 24 Feb 2020 05:43:03 +0100

Spring MVC self study log 07 (Mybatic integration)

Integration steps Import related jar package <!--junit--> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.12</version> </dependency> <!--mybatis--> <dependency> <groupId>org.mybatis& ...

Posted by jamal dakak on Thu, 13 Feb 2020 16:50:30 +0100

[Vue] make a message board interface

Interface display Highlights: The color and length of the card can be changed randomly, and the page length layout can be adaptive. Users can click like. Get ready MySQL A message table:Message: message content; username: processed by the backend. If the submitted one is empty, set the name to ...

Posted by Iasonic on Mon, 10 Feb 2020 13:28:26 +0100

SpringBoot2.x learning - integrated Mybatis framework

1, Add startup dependency Add dependency in maven file of spring boot project as follows: <properties> <java.version>1.8</java.version> <druid.version>1.1.13</druid.version> <mybatis.version>2.1.0</mybatis.version> <druid ...

Posted by AngelG107 on Sat, 08 Feb 2020 13:55:09 +0100

Integration of SSM framework

1. Create database first 2. Create project 3. Import required coordinates 4. Configure mybatis (using annotation method), and write SqlMapConfig.xml, the content is as follows (Dao layer configuration), and test <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE configuration PUBLI ...

Posted by snrecords on Wed, 05 Feb 2020 16:23:23 +0100

How to write the SSM integration configuration file?

Article directory 1, Setting up the environment 1. Create Maven project 2. Import dependency 1. Version lock 2. Import dependencies dependencies 3. Write entity class 2, Integration 1. Configure SqlMapConfig.xml 2. Configure springmvc.xml 3. Configure applicationContext.xml (the commonly used na ...

Posted by StefanRSA on Tue, 04 Feb 2020 18:25:11 +0100