Tagged articles

MyBatis

762 articles · Page 6 of 8
Full-Stack Internet Architecture
Full-Stack Internet Architecture
Oct 15, 2021 · Backend Development

Comprehensive Guide to MyBatis Batch Insert: Three Methods, Performance Comparison, and Analysis

This article introduces three MyBatis batch insertion techniques—looped single inserts, MyBatis‑Plus batch inserts, and native SQL batch inserts—provides complete implementation code, performance test results for inserting 100,000 records, analyzes the causes of differences, and offers practical solutions to common pitfalls such as MySQL packet size limits.

Batch InsertMyBatisMySQL
0 likes · 13 min read
Comprehensive Guide to MyBatis Batch Insert: Three Methods, Performance Comparison, and Analysis
Selected Java Interview Questions
Selected Java Interview Questions
Oct 12, 2021 · Backend Development

Implementing MyBatis Streaming Queries with Cursor and Keeping Database Connections Open

The article explains the concept of streaming queries in MyBatis, introduces the Cursor interface, demonstrates how to use it in Spring MVC controllers, and provides three practical solutions—SqlSessionFactory, TransactionTemplate, and @Transactional—to keep the database connection open during iteration.

CursorMyBatisSpring
0 likes · 7 min read
Implementing MyBatis Streaming Queries with Cursor and Keeping Database Connections Open
Top Architect
Top Architect
Oct 8, 2021 · Backend Development

Comparative Analysis of Java Persistence Frameworks: JOOQ, MyBatis, Hibernate, JPA, and JDBC Template

The article presents a senior architect’s detailed comparison of Java persistence solutions—JOOQ, MyBatis, Hibernate, JPA, and JDBC Template—examining SQL encapsulation, DSL support, cross‑database portability, security, and practical trade‑offs, ultimately recommending JDBC Template for the project.

Framework ComparisonHibernateJDBC
0 likes · 12 min read
Comparative Analysis of Java Persistence Frameworks: JOOQ, MyBatis, Hibernate, JPA, and JDBC Template
Java Architect Essentials
Java Architect Essentials
Sep 27, 2021 · Backend Development

Comparative Analysis of Java Persistence Frameworks: Hibernate, MyBatis, JOOQ, Ebean, Spring Data JPA and JDBC Template

The article evaluates major Java persistence solutions—Hibernate, MyBatis, JOOQ, Ebean, Spring Data JPA and JDBC Template—by comparing their SQL encapsulation, DSL support, cross‑database portability, performance, and security, ultimately recommending JDBC Template for the author's project.

HibernateJDBCJOOQ
0 likes · 13 min read
Comparative Analysis of Java Persistence Frameworks: Hibernate, MyBatis, JOOQ, Ebean, Spring Data JPA and JDBC Template
Java Architect Essentials
Java Architect Essentials
Sep 25, 2021 · Backend Development

Implementing Read‑Write Splitting in Spring Boot with AbstractRoutingDataSource and AOP

This article explains how to achieve read‑write splitting in a Spring Boot application by configuring multiple data sources, creating a custom AbstractRoutingDataSource, managing routing keys with ThreadLocal, and using AOP to automatically switch between master and slave databases for different CRUD operations.

AOPDataSource RoutingMyBatis
0 likes · 12 min read
Implementing Read‑Write Splitting in Spring Boot with AbstractRoutingDataSource and AOP
Top Architect
Top Architect
Sep 25, 2021 · Backend Development

Hospital Registration System Using Java Spring MVC, MyBatis, and MySQL

This article provides a step‑by‑step tutorial for building a hospital registration web application with Java, Spring MVC, MyBatis, JSP pages, and MySQL, covering environment setup, database schema, DAO interfaces, service implementation, controller logic, and front‑end pages.

JSPMyBatisMySQL
0 likes · 18 min read
Hospital Registration System Using Java Spring MVC, MyBatis, and MySQL
Java Architect Essentials
Java Architect Essentials
Sep 23, 2021 · Backend Development

MyBatis Dynamic SQL: Using if, choose, foreach, trim, and bind Tags with Practical Code Samples

This article demonstrates how MyBatis dynamic SQL simplifies conditional query building by explaining the usage of if, choose, foreach, trim, and bind tags, providing Maven project setup, table creation scripts, mapper interfaces, XML snippets, and unit test examples for SELECT, UPDATE, INSERT, and batch operations.

DatabaseDynamic SQLMyBatis
0 likes · 19 min read
MyBatis Dynamic SQL: Using if, choose, foreach, trim, and bind Tags with Practical Code Samples
Alibaba Cloud Developer
Alibaba Cloud Developer
Sep 7, 2021 · Information Security

How to Prevent SQL Injection in MyBatis and Other ORM Frameworks

This article explains the principles behind SQL injection, common pitfalls in MyBatis and other ORM tools, and provides concrete safe coding patterns, configuration tips, and code examples to help developers eliminate injection vulnerabilities in their persistence layer.

MyBatisORM securitySQL injection
0 likes · 15 min read
How to Prevent SQL Injection in MyBatis and Other ORM Frameworks
Java Captain
Java Captain
Sep 4, 2021 · Backend Development

Hospital Registration System Using Java Spring MVC and MyBatis

This article presents a complete Java‑based hospital registration system built with Spring MVC, MyBatis, and JSP, detailing the development environment, database schema, source code for controllers, DAOs, services, configuration files, and web pages to enable patient search, registration, and status updates.

Hospital ManagementJSPMyBatis
0 likes · 24 min read
Hospital Registration System Using Java Spring MVC and MyBatis
High Availability Architecture
High Availability Architecture
Sep 3, 2021 · Backend Development

MyBatis Complete Example and Internal Architecture Overview

This article provides a thorough introduction to MyBatis, including a complete beginner example with database schema, Maven configuration, XML and Java mapper files, and a demo program, followed by an in‑depth explanation of MyBatis’s lifecycle, core components such as SqlSession, Executor, StatementHandler, ParameterHandler, ResultSetHandler, and their interactions.

DatabaseExecutorMyBatis
0 likes · 27 min read
MyBatis Complete Example and Internal Architecture Overview
vivo Internet Technology
vivo Internet Technology
Sep 2, 2021 · Backend Development

Complete MyBatis Example and Architecture Overview

The article presents a step‑by‑step MyBatis tutorial that creates a sample user table, adds Maven dependencies, configures MyBatis, defines mapper XML and Java interfaces, demonstrates a test program, and explains core components such as SqlSession, Executor, StatementHandler, ParameterHandler, and ResultSetHandler.

ExecutorMyBatisORM
0 likes · 28 min read
Complete MyBatis Example and Architecture Overview
Java Architecture Diary
Java Architecture Diary
Sep 2, 2021 · Backend Development

Master MyBatis‑Mate: Dictionary Binding, Encryption, Sharding & Data Scope Explained

This guide introduces MyBatis‑Mate’s core capabilities—including dictionary binding, field encryption, data masking, automatic DDL maintenance, dynamic sharding, and data‑scope permissions—while providing Maven dependencies and complete Java code examples for integrating these features into Spring Boot applications.

Data PermissionMyBatisSharding
0 likes · 8 min read
Master MyBatis‑Mate: Dictionary Binding, Encryption, Sharding & Data Scope Explained
Java Backend Technology
Java Backend Technology
Aug 29, 2021 · Backend Development

Which Java Persistence Framework Wins? A Deep Comparison of JOOQ, MyBatis, Hibernate, JPA, and JDBC Template

This article evaluates popular and niche Java persistence frameworks—Hibernate, MyBatis, JOOQ, Ebean, JPA, and Spring JDBC Template—by comparing SQL encapsulation, performance, DSL support, cross‑database portability, and security, ultimately explaining why the author chose JDBC Template for their project.

Framework ComparisonJOOQMyBatis
0 likes · 13 min read
Which Java Persistence Framework Wins? A Deep Comparison of JOOQ, MyBatis, Hibernate, JPA, and JDBC Template
Java High-Performance Architecture
Java High-Performance Architecture
Aug 25, 2021 · Backend Development

13 Essential Java Coding Practices to Boost Performance and Cleanliness

This article presents a comprehensive guide to writing more standardized Java code, covering topics such as avoiding "1=1" in MyBatis, iterating Map entrySet, pre‑sizing collections, using StringBuilder, preferring Set for contains checks, proper static initialization, removing unused variables, shielding utility constructors, eliminating redundant exception handling, using String.valueOf, avoiding BigDecimal(double), returning empty collections instead of null, safe equals usage, immutable enum fields, and correctly escaping regex in String.split, each illustrated with clear code examples.

ExceptionsMyBatiscoding standards
0 likes · 15 min read
13 Essential Java Coding Practices to Boost Performance and Cleanliness
Programmer DD
Programmer DD
Aug 25, 2021 · Databases

How to Efficiently Insert Massive Data Without Duplicates in MySQL

This article explains several MySQL techniques—INSERT IGNORE, ON DUPLICATE KEY UPDATE, INSERT…SELECT WHERE NOT EXISTS, and REPLACE—plus a practical MyBatis batch‑insert example, to handle large‑scale data imports while preventing duplicate records.

Batch InsertMyBatisSQL
0 likes · 5 min read
How to Efficiently Insert Massive Data Without Duplicates in MySQL
Selected Java Interview Questions
Selected Java Interview Questions
Aug 23, 2021 · Backend Development

Optimizing Bulk Data Import into MySQL with MyBatis: From Simple List Insertion to Multi‑Threaded Batch Processing

This article demonstrates how to dramatically speed up importing tens of thousands of records into MySQL by evolving a naïve list‑to‑MySQL approach into grouped batch inserts and finally a multi‑threaded MyBatis solution, while also addressing packet size limits and configuration tweaks.

Batch InsertMyBatisMySQL
0 likes · 9 min read
Optimizing Bulk Data Import into MySQL with MyBatis: From Simple List Insertion to Multi‑Threaded Batch Processing
Top Architect
Top Architect
Aug 20, 2021 · Databases

Querying Multi‑Business Unit Product Sales Statistics with MySQL and MyBatis Dynamic SQL

This article explains how to retrieve sales statistics for multiple business units and their associated products from a MySQL table, compares several implementation approaches—including loop queries, OR concatenation, mixed filtering, and row‑comparison using MyBatis dynamic SQL—evaluates index usage, and provides the final recommended solution.

Database QueryDynamic SQLMyBatis
0 likes · 8 min read
Querying Multi‑Business Unit Product Sales Statistics with MySQL and MyBatis Dynamic SQL
Java Captain
Java Captain
Aug 15, 2021 · Databases

Querying Multi‑Business Unit Sales Statistics Using Row Comparison in MySQL

The article describes how to design a MySQL table for product sales statistics, initialize large data sets, and compare several approaches—including loop queries, OR concatenation, mixed filtering, and row‑comparison techniques—ultimately selecting row‑comparison as the most efficient solution within MyBatis dynamic SQL constraints.

Database DesignDynamic SQLMyBatis
0 likes · 6 min read
Querying Multi‑Business Unit Sales Statistics Using Row Comparison in MySQL
Programmer DD
Programmer DD
Aug 3, 2021 · Databases

Why MySQL Uses B+ Trees for Indexes and How to Design Effective Indexes

This article explains why MySQL chooses B+ trees for its indexes, covers the left‑most prefix rule for composite indexes, offers practical index‑design tips, discusses MyBatis caching, master‑slave replication, and sharding strategies for large‑scale databases.

B+TreeMyBatisSharding
0 likes · 10 min read
Why MySQL Uses B+ Trees for Indexes and How to Design Effective Indexes
Java Captain
Java Captain
Aug 1, 2021 · Backend Development

How to Write More Standardized Java Code

This article presents a comprehensive set of Java coding best‑practice guidelines—ranging from MyBatis query writing, efficient Map iteration, collection handling, StringBuilder usage, to proper enum design and exception handling—each illustrated with clear anti‑pattern and correct‑pattern code examples.

CollectionsExceptionsMyBatis
0 likes · 14 min read
How to Write More Standardized Java Code
Programmer DD
Programmer DD
Jul 31, 2021 · Backend Development

Build a Spring Boot Web Crawler with WebMagic, MyBatis, and MySQL

This tutorial demonstrates how to combine Spring Boot, WebMagic, and MyBatis to crawl Zhihu pages, configure Maven dependencies, set up MySQL data sources, define entity and mapper classes, and schedule the crawler to run periodically, providing a complete Java web‑crawling scaffold.

MyBatisSpring BootWebMagic
0 likes · 14 min read
Build a Spring Boot Web Crawler with WebMagic, MyBatis, and MySQL
Java Architecture Diary
Java Architecture Diary
Jul 28, 2021 · Backend Development

Unlock Enterprise‑Level Data Handling with MyBatis‑Mate 1.0.1: Features & Code Guide

The release of MyBatis‑Mate 1.0.1 introduces enterprise‑grade features such as dictionary binding, field encryption, data desensitization, automatic DDL maintenance, and dynamic multi‑datasource sharding, accompanied by code examples, future roadmap, and Maven dependencies for seamless integration into Spring Boot projects.

DDLDictionary BindingMyBatis
0 likes · 7 min read
Unlock Enterprise‑Level Data Handling with MyBatis‑Mate 1.0.1: Features & Code Guide
Java Backend Technology
Java Backend Technology
Jul 20, 2021 · Backend Development

How to Implement Efficient MyBatis Streaming Queries in Spring

Streaming queries return an iterator instead of a full result set, reducing memory usage, but require keeping the database connection open; this guide explains MyBatis’s Cursor interface, its methods, and three practical ways—using SqlSessionFactory, TransactionTemplate, or @Transactional—to safely perform MyBatis streaming queries in Spring.

CursorDatabaseMyBatis
0 likes · 7 min read
How to Implement Efficient MyBatis Streaming Queries in Spring
Code Ape Tech Column
Code Ape Tech Column
Jul 12, 2021 · Information Security

MyBatis SQL Injection Auditing: Common Vulnerabilities and Practical Analysis

This article explains how SQL injection can still occur in Java applications using MyBatis, describes the three typical vulnerable patterns (LIKE, IN, ORDER BY), and provides a step‑by‑step practical workflow—including code snippets and verification—to help beginners audit and remediate such issues.

Code AuditingMyBatisORM
0 likes · 7 min read
MyBatis SQL Injection Auditing: Common Vulnerabilities and Practical Analysis
Top Architect
Top Architect
Jul 11, 2021 · Databases

Handling Duplicate Inserts in MySQL: Strategies and MyBatis Batch Example

The article discusses efficient ways to perform bulk inserts in MySQL while avoiding duplicate records, covering techniques such as INSERT IGNORE, ON DUPLICATE KEY UPDATE, INSERT…SELECT…WHERE NOT EXISTS, REPLACE INTO, and demonstrates a practical MyBatis implementation with a unique mobile_number constraint.

Batch InsertINSERT IGNOREMyBatis
0 likes · 5 min read
Handling Duplicate Inserts in MySQL: Strategies and MyBatis Batch Example
Programmer DD
Programmer DD
Jul 11, 2021 · Databases

Inside MyBatis Transactions: The Real Story of JDBC Commit, Rollback & Close

This article demystifies MyBatis transaction handling by explaining the true JDBC methods—setAutoCommit, commit, rollback—and clarifying common misconceptions about create, begin, close, and suspend, while exploring MyBatis’s Transaction, TransactionFactory, and practical code examples that illustrate how commits, rollbacks, and connection closing behave in various scenarios.

DatabaseJDBCMyBatis
0 likes · 10 min read
Inside MyBatis Transactions: The Real Story of JDBC Commit, Rollback & Close
Code Ape Tech Column
Code Ape Tech Column
Jul 9, 2021 · Backend Development

How to Keep MyBatis Streaming Queries Alive: Three Practical Solutions

This article explains the concept of MyBatis streaming queries, why keeping the database connection open is essential, and provides three concrete approaches—using SqlSessionFactory, TransactionTemplate, or @Transactional—to ensure cursors remain usable without premature closure.

CursorDatabaseMyBatis
0 likes · 7 min read
How to Keep MyBatis Streaming Queries Alive: Three Practical Solutions
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Jul 3, 2021 · Backend Development

How to Configure Master‑Slave Data Sources in Spring Boot with JPA & MyBatis

This guide walks through setting up a Spring Boot 2.1.4 application with JDK 1.8, Oracle, and HikariCP to use separate master and slave data sources, covering Maven dependencies, YAML configuration, custom property classes, JPA EntityManager factories, MyBatis SqlSession factories, mapper scanning, and sample entity definitions.

HikariCPJPAMultiple Data Sources
0 likes · 19 min read
How to Configure Master‑Slave Data Sources in Spring Boot with JPA & MyBatis
Full-Stack Internet Architecture
Full-Stack Internet Architecture
Jun 29, 2021 · Databases

Quick Integration of ShardingSphere for Database Sharding in Spring Boot

This article explains how to use Spring Boot to quickly integrate ShardingSphere for database sharding, covering the background of massive data storage challenges, the advantages of ShardingSphere, step‑by‑step project setup, configuration of data sources and sharding strategies, and a complete test example.

Inline Sharding StrategyMyBatisSharding-JDBC
0 likes · 13 min read
Quick Integration of ShardingSphere for Database Sharding in Spring Boot
Top Architect
Top Architect
Jun 22, 2021 · Backend Development

Step-by-Step Guide to Building a Spring Boot Project with MyBatis and MySQL

This tutorial walks through creating a Spring Boot project, configuring Maven dependencies, setting up application.yml and properties, defining POJOs, MyBatis mapper XML, service and controller layers, and building simple Thymeleaf login and registration pages, with full code snippets for each step.

MyBatisMySQLSpring Boot
0 likes · 10 min read
Step-by-Step Guide to Building a Spring Boot Project with MyBatis and MySQL
Programmer DD
Programmer DD
Jun 22, 2021 · Backend Development

Explore a Complete Java E‑Commerce Platform with Spring, MyBatis & Vue

This article presents a full‑stack Java mall project with distribution features, detailing its object‑oriented advantages, comprehensive backend and frontend technology stack, project structure, implemented modules such as member management, product editing, promotion, order and system management, deployment environment, and provides source code and documentation for developers.

MyBatisSpringVue
0 likes · 6 min read
Explore a Complete Java E‑Commerce Platform with Spring, MyBatis & Vue
21CTO
21CTO
Jun 10, 2021 · Databases

Which Java DAO Framework Is Right for Your Project? A Comparative Guide

An in‑depth comparison of popular Java DAO frameworks—including JDBC, JOOQ, MyBatis, Hibernate, and Spring Data—covers their core concepts, code examples, ideal use cases, and limitations, helping developers choose the most suitable data‑access layer for their projects.

DAOHibernateJDBC
0 likes · 7 min read
Which Java DAO Framework Is Right for Your Project? A Comparative Guide
Java Architect Essentials
Java Architect Essentials
Jun 9, 2021 · Backend Development

Using MyBatis Generator for Code Generation and Practical CRUD Examples

This article explains how to set up the MyBatis Generator plugin in a Maven project, configure generatorConfig.xml and jdbc.properties, and demonstrates practical CRUD operations such as deleting users, updating team information, and performing fuzzy and range queries with generated Example classes.

MyBatisORMbackend development
0 likes · 9 min read
Using MyBatis Generator for Code Generation and Practical CRUD Examples
Java High-Performance Architecture
Java High-Performance Architecture
Jun 5, 2021 · Backend Development

How to Implement Efficient MyBatis Streaming Queries in Spring MVC

This article explains the concept of streaming queries, introduces MyBatis's Cursor interface, demonstrates common pitfalls such as closed cursors, and provides three practical solutions—using SqlSessionFactory, TransactionTemplate, or @Transactional—to keep database connections open while processing large result sets.

CursorDatabaseMyBatis
0 likes · 7 min read
How to Implement Efficient MyBatis Streaming Queries in Spring MVC
Alibaba Cloud Developer
Alibaba Cloud Developer
Jun 4, 2021 · Backend Development

Why Fluent MyBatis Outshines MyBatis Plus and JOOQ for Java SQL Building

This article examines the evolution of Java SQL‑mapping frameworks, compares MyBatis, MyBatis Plus, MyBatis Dynamic SQL, JOOQ and the newer Fluent MyBatis, highlights Fluent MyBatis’s code‑centric design, IDE support, dynamic table naming, and provides practical code examples to illustrate its advantages.

Fluent-MyBatisJava ORMMyBatis
0 likes · 16 min read
Why Fluent MyBatis Outshines MyBatis Plus and JOOQ for Java SQL Building
Full-Stack Internet Architecture
Full-Stack Internet Architecture
May 20, 2021 · Backend Development

Template Method Design Pattern in Java: Theory, Implementation, and Framework Applications

This article explains the Template Method design pattern, illustrating its algorithm skeleton and step customization with Java code examples, and demonstrates real‑world applications in Spring, MyBatis, and other backend frameworks, highlighting advantages, drawbacks, and practical implementation details.

Design PatternMyBatisSpring
0 likes · 12 min read
Template Method Design Pattern in Java: Theory, Implementation, and Framework Applications
vivo Internet Technology
vivo Internet Technology
May 19, 2021 · Backend Development

MyBatis-Plus SQL Auto-Injection Principle Analysis

MyBatis‑Plus enhances MyBatis by automatically injecting CRUD SQL via BaseMapper, using entity annotations and template methods to map classes to tables, eliminating repetitive manual SQL, supporting lambda queries, pagination, and performance tools, all with minimal intrusion and overhead.

BaseMapperMyBatisORM
0 likes · 10 min read
MyBatis-Plus SQL Auto-Injection Principle Analysis
Top Architect
Top Architect
May 19, 2021 · Databases

MyBatis Streaming Query: Cursor Interface and Practical Implementations

This article explains MyBatis streaming queries using the Cursor interface, demonstrates how to define a Mapper that returns a Cursor, shows common pitfalls with closed connections, and provides three solutions—manual SqlSession handling, TransactionTemplate, and @Transactional—to keep the database connection open while iterating results.

CursorDatabaseMyBatis
0 likes · 7 min read
MyBatis Streaming Query: Cursor Interface and Practical Implementations
Architecture Digest
Architecture Digest
May 19, 2021 · Backend Development

Why MyBatis Treats Integer 0 as an Empty String in <if> Conditions

When using MyBatis dynamic SQL to filter records by a numeric state field, the framework incorrectly evaluates the condition "state != ''" as false for the integer value 0 because its OGNL expression evaluator treats 0 as equivalent to an empty string, leading to unexpected query results.

Dynamic SQLInteger ComparisonMyBatis
0 likes · 7 min read
Why MyBatis Treats Integer 0 as an Empty String in <if> Conditions
Java Architect Essentials
Java Architect Essentials
May 7, 2021 · Backend Development

Comprehensive Spring Boot Integration Guide: Swagger, Redis, MyBatis, Druid, Mail, CORS, AOP and More

This article provides a step‑by‑step tutorial on building a Spring Boot project, covering project generation, core starters, automatic Redis configuration, common annotations like @SpringBootApplication and @ControllerAdvice, web container and HTTPS settings, profile management, CORS, MVC interceptors, AOP, MyBatis‑Druid integration, mail sending, and Swagger API documentation.

IntegrationMailMyBatis
0 likes · 18 min read
Comprehensive Spring Boot Integration Guide: Swagger, Redis, MyBatis, Druid, Mail, CORS, AOP and More
Code Ape Tech Column
Code Ape Tech Column
May 6, 2021 · Backend Development

Why PageHelper Pagination Breaks with List Operations and How to Fix It

This article explains why PageHelper pagination yields incorrect totals when list operations are performed before or after pagination, analyzes the underlying cause that startPage only affects subsequent SQL, and provides a step‑by‑step solution that processes the list after pagination and returns a correctly populated PageInfo object.

MyBatisSpringbackend
0 likes · 6 min read
Why PageHelper Pagination Breaks with List Operations and How to Fix It
Architecture Digest
Architecture Digest
Apr 28, 2021 · Backend Development

Comprehensive Spring Boot Integration Guide: MyBatis, Druid, Redis, Swagger, Email, CORS, AOP and More

This article provides a step‑by‑step tutorial on building a Spring Boot project and configuring essential features such as starters, configuration properties, profiles, global exception handling, CORS, MVC interceptors, AOP, MyBatis‑Druid integration, Redis caching, email sending, and Swagger API documentation, complete with code examples and best‑practice tips.

IntegrationMyBatisSpring Boot
0 likes · 20 min read
Comprehensive Spring Boot Integration Guide: MyBatis, Druid, Redis, Swagger, Email, CORS, AOP and More
Programmer DD
Programmer DD
Apr 21, 2021 · Backend Development

Unveiling MyBatis: How Mapper Interfaces Bind and SQL Executes Internally

This article thoroughly dissects MyBatis’s internal workflow, explaining how mapper interfaces are linked to XML files, detailing the step‑by‑step SQL execution process, and demonstrating custom typeHandler creation for both parameter and result mapping, all based on MyBatis 3.5.5 source code.

MyBatisORMSQL execution
0 likes · 17 min read
Unveiling MyBatis: How Mapper Interfaces Bind and SQL Executes Internally
Top Architect
Top Architect
Apr 19, 2021 · Databases

Understanding MySQL Index Structures, B+ Trees, and Practical Optimization Techniques

This article explains why MySQL uses B+‑tree indexes, describes the left‑most prefix rule for composite indexes, offers practical index‑design and optimization tips, outlines MyBatis first‑ and second‑level caching, details master‑slave replication, and introduces common sharding strategies and their implementation considerations.

B+TreeMyBatisMySQL
0 likes · 12 min read
Understanding MySQL Index Structures, B+ Trees, and Practical Optimization Techniques
Code Ape Tech Column
Code Ape Tech Column
Apr 13, 2021 · Backend Development

Implementing Sensitive Data Encryption and Decryption in Spring Boot with MyBatis Interceptors and Custom Annotations

This article demonstrates how to automatically encrypt sensitive fields such as ID numbers and phone numbers before storing them in a database and decrypt them after retrieval by using Spring Boot, MyBatis plugins, and custom annotations, eliminating manual encryption logic in business code.

AnnotationInterceptorMyBatis
0 likes · 11 min read
Implementing Sensitive Data Encryption and Decryption in Spring Boot with MyBatis Interceptors and Custom Annotations
Full-Stack Internet Architecture
Full-Stack Internet Architecture
Apr 7, 2021 · Backend Development

Nine MyBatis SQL Tricks for SpringBoot Web Applications (MySQL Example)

This article presents nine practical MyBatis techniques—including pagination, preset column selection, one‑to‑many and one‑to‑one associations, foreach‑in queries, dynamic where clauses, choose/otherwise logic, hidden _parameter usage, and dynamic set updates—illustrated with SpringBoot and MySQL code examples.

Dynamic SQLMyBatisMySQL
0 likes · 6 min read
Nine MyBatis SQL Tricks for SpringBoot Web Applications (MySQL Example)
Java Interview Crash Guide
Java Interview Crash Guide
Apr 2, 2021 · Backend Development

How MyBatis Leverages 9 Classic Design Patterns in Its Core

This article explores how MyBatis implements nine fundamental design patterns—including Builder, Factory, Singleton, Proxy, Composite, Template Method, Adapter, Decorator, and Iterator—by examining its source code, illustrating each pattern with concrete classes, code snippets, and diagrams to deepen developers' understanding of design patterns in practice.

BuilderMyBatisbackend development
0 likes · 19 min read
How MyBatis Leverages 9 Classic Design Patterns in Its Core
Selected Java Interview Questions
Selected Java Interview Questions
Apr 2, 2021 · Backend Development

Design Patterns in MyBatis: Builder, Factory, Singleton, Proxy, Composite, Template Method, Adapter, Decorator, and Iterator

This article analyses how MyBatis applies nine classic design patterns—Builder, Factory, Singleton, Proxy, Composite, Template Method, Adapter, Decorator, and Iterator—by examining its source code, illustrating each pattern with explanations and concrete Java examples to deepen understanding of software design in backend development.

Design PatternsMyBatisbackend development
0 likes · 20 min read
Design Patterns in MyBatis: Builder, Factory, Singleton, Proxy, Composite, Template Method, Adapter, Decorator, and Iterator
Selected Java Interview Questions
Selected Java Interview Questions
Mar 23, 2021 · Backend Development

Understanding MyBatis: Concepts, Advantages, Disadvantages, Usage Scenarios, and Advanced Features

This article provides a comprehensive overview of MyBatis, a semi‑ORM Java framework, covering its core concepts, benefits, drawbacks, appropriate use cases, differences from Hibernate, parameter handling, dynamic SQL, caching, lazy loading, mapper binding, plugin development, and various configuration techniques.

MyBatisORMPersistence
0 likes · 22 min read
Understanding MyBatis: Concepts, Advantages, Disadvantages, Usage Scenarios, and Advanced Features
Code Ape Tech Column
Code Ape Tech Column
Mar 18, 2021 · Backend Development

Master MyBatis: Core Concepts, Best Practices, and Advanced Techniques

This comprehensive guide explains what MyBatis is, its advantages and drawbacks, suitable use cases, differences from Hibernate, parameter handling, dynamic SQL, pagination, caching, lazy loading, and how to use mapper interfaces, XML mappings, and plugins with clear code examples.

MyBatisORMPersistence
0 likes · 20 min read
Master MyBatis: Core Concepts, Best Practices, and Advanced Techniques
Code Ape Tech Column
Code Ape Tech Column
Mar 1, 2021 · Backend Development

Optimizing Large‑Scale Excel Import in Java: From POI to EasyExcel with Caching, Batch Inserts, and Parallel Streams

This article describes how to dramatically speed up the import of massive Excel files in a Java backend by replacing raw POI with EasyExcel, caching database lookups, using MySQL batch inserts, and employing parallel streams to achieve sub‑minute processing for hundreds of thousands of rows.

Batch InsertEasyExcelExcel import
0 likes · 12 min read
Optimizing Large‑Scale Excel Import in Java: From POI to EasyExcel with Caching, Batch Inserts, and Parallel Streams
Top Architect
Top Architect
Feb 28, 2021 · Backend Development

Optimizing Large Excel Import Performance in Java Backend Applications

This article details a step‑by‑step optimization of a Java backend Excel import pipeline, covering migration from POI to EasyExcel, caching database lookups, batch insertion with MySQL VALUES, and parallel processing to reduce a 100k‑row import from minutes to under two minutes.

ExcelMyBatisParallelProcessing
0 likes · 10 min read
Optimizing Large Excel Import Performance in Java Backend Applications
Java Captain
Java Captain
Feb 21, 2021 · Backend Development

Step-by-Step Guide to Building a Spring Boot Application with MyBatis and MySQL

This tutorial walks through creating a Spring Boot project, configuring Maven dependencies, setting up MySQL with MyBatis, defining entity, mapper, service, and controller layers, and building simple Thymeleaf login and registration pages, culminating in a runnable dynamic authentication demo.

MyBatisMySQLSpring Boot
0 likes · 16 min read
Step-by-Step Guide to Building a Spring Boot Application with MyBatis and MySQL
Top Architect
Top Architect
Feb 17, 2021 · Backend Development

Understanding and Optimizing MyBatis PageHelper Pagination Performance

This article analyzes the performance bottlenecks of PageHelper's pagination in MyBatis, demonstrates how large offsets degrade MySQL query speed, and presents a more efficient sub‑query join solution along with suggestions for refactoring the interceptor to improve backend pagination efficiency.

MyBatisSQLbackend
0 likes · 9 min read
Understanding and Optimizing MyBatis PageHelper Pagination Performance
Su San Talks Tech
Su San Talks Tech
Feb 14, 2021 · Fundamentals

7 Common Java String Pitfalls and How to Avoid Them

This article walks through frequent Java string‑related mistakes—including misuse of replace vs replaceAll, Integer equality pitfalls, BigDecimal precision issues, StringBuilder versus String, isEmpty vs isBlank, MyBatis mapper null checks, and indexOf logic—providing clear explanations, code examples, and best‑practice recommendations.

BigDecimalCode ReviewMyBatis
0 likes · 13 min read
7 Common Java String Pitfalls and How to Avoid Them
Top Architect
Top Architect
Jan 27, 2021 · Databases

MyBatis Streaming Query (Cursor) – Keeping the Database Connection Open

This article explains what a streaming query is, introduces MyBatis's Cursor interface and its methods, demonstrates common pitfalls such as the cursor being closed prematurely, and provides three practical solutions using SqlSessionFactory, TransactionTemplate, and @Transactional to keep the database connection alive during streaming reads.

CursorDatabase ConnectionMyBatis
0 likes · 7 min read
MyBatis Streaming Query (Cursor) – Keeping the Database Connection Open
Huawei Cloud Developer Alliance
Huawei Cloud Developer Alliance
Jan 26, 2021 · Backend Development

Master MyBatis: Common Return Values, Exceptions, and SQL Optimization Tips

This article shares practical MyBatis tips, detailing what different return types yield when no records match, common exceptions you may encounter, transaction lock behavior with FOR UPDATE, and essential SQL optimization strategies such as using LIMIT, proper indexing, and avoiding inefficient patterns.

Database PerformanceJava PersistenceMyBatis
0 likes · 8 min read
Master MyBatis: Common Return Values, Exceptions, and SQL Optimization Tips
Selected Java Interview Questions
Selected Java Interview Questions
Jan 17, 2021 · Backend Development

Lombok Getter/Setter Pitfalls with MyBatis and @Accessor(chain=true) Issues in EasyExcel

This article explains why Lombok-generated getter/setter methods for fields whose second character is uppercase can cause MyBatis to store null values, shows the MyBatis PropertyNamer logic that leads to the problem, and also describes how the @Accessor(chain=true) annotation interferes with EasyExcel's reflection‑based export, offering practical workarounds for both issues.

EasyExcelGetterSetterLombok
0 likes · 9 min read
Lombok Getter/Setter Pitfalls with MyBatis and @Accessor(chain=true) Issues in EasyExcel
Architecture Digest
Architecture Digest
Jan 16, 2021 · Backend Development

Understanding MyBatis SQL Execution Process and Custom TypeHandler Implementation

This article explains how MyBatis binds mapper interfaces to XML files, details the step‑by‑step SQL execution flow—including mapper retrieval, statement lookup, parameter handling, and result set mapping—and demonstrates how to create custom TypeHandler classes for both parameter setting and result extraction.

MyBatisSQL executionTypeHandler
0 likes · 16 min read
Understanding MyBatis SQL Execution Process and Custom TypeHandler Implementation
Java Captain
Java Captain
Jan 16, 2021 · Backend Development

Cinema Ticketing System Project Overview

This article presents a cinema ticketing system built with the SSM framework, MySQL, Redis, Alipay sandbox, LayUI, and Baidu ECharts, highlighting its architecture, features such as payment and seat selection, and providing source code link and screenshots.

AlipayEChartsMyBatis
0 likes · 1 min read
Cinema Ticketing System Project Overview
Programmer DD
Programmer DD
Jan 14, 2021 · Backend Development

Why Spring Data JPA Can Slow Down Team Maintenance and When to Choose MyBatis

The article compares Spring Data JPA and MyBatis, highlighting that while Spring Data JPA speeds up individual development, it can create maintenance challenges for teams, especially when tracking slow queries, and argues that MyBatis may be a better choice for collaborative projects.

Java PersistenceMyBatisTeam Maintenance
0 likes · 3 min read
Why Spring Data JPA Can Slow Down Team Maintenance and When to Choose MyBatis
Code Ape Tech Column
Code Ape Tech Column
Jan 12, 2021 · Backend Development

Master MyBatis Streaming Queries: Avoid Cursor Closure Errors with Three Simple Solutions

This article explains the concept of streaming queries in MyBatis, describes the Cursor interface and its methods, demonstrates common pitfalls that cause cursor closure errors, and provides three practical solutions—using SqlSessionFactory, TransactionTemplate, or @Transactional—to keep the database connection open during iteration.

CursorMyBatisSpring
0 likes · 8 min read
Master MyBatis Streaming Queries: Avoid Cursor Closure Errors with Three Simple Solutions
Architecture Digest
Architecture Digest
Jan 6, 2021 · Backend Development

Optimizing Large-Scale Excel Import Performance in Java Backend Applications

This article details a step‑by‑step optimization of a Java backend Excel import pipeline, covering data validation caching, batch insertion with MySQL VALUES, switching to EasyExcel, parallel stream insertion, and logging reduction to achieve sub‑minute import times for hundreds of thousands of rows.

EasyExcelExcelMyBatis
0 likes · 11 min read
Optimizing Large-Scale Excel Import Performance in Java Backend Applications
Architect's Tech Stack
Architect's Tech Stack
Dec 29, 2020 · Databases

Implementing Database Read‑Write Separation with Spring Boot and MyBatis

This article explains how to implement database read‑write separation in a Spring Boot application using Druid connection pools, custom DataSource routing, a ThreadLocal context holder, and AOP‑based annotations, providing step‑by‑step configuration and usage examples with full Java code.

DataSource RoutingMyBatisRead-Write Separation
0 likes · 11 min read
Implementing Database Read‑Write Separation with Spring Boot and MyBatis
Code Ape Tech Column
Code Ape Tech Column
Dec 29, 2020 · Backend Development

Unveiling MyBatis: How Mapper Binding and SQL Execution Work Internally

This article dissects MyBatis 3.5.5’s internal workflow, explaining how mapper interfaces bind to XML files, the step‑by‑step SQL execution process, custom typeHandler creation for parameter and result mapping, and the underlying proxy and configuration mechanisms that drive query handling.

MyBatisSQL executionTypeHandler
0 likes · 17 min read
Unveiling MyBatis: How Mapper Binding and SQL Execution Work Internally
macrozheng
macrozheng
Dec 28, 2020 · Backend Development

Master MyBatis Dynamic SQL: Eliminate XML Mappers and Supercharge CRUD

This tutorial explains how to replace verbose MyBatis mapper XML files with the modern Dynamic SQL API, covering setup, Maven dependencies, configuration, code generation, CRUD operations, advanced queries, subqueries, joins, conditional updates, and one‑to‑many mappings for Java backend development.

CRUDDynamic SQLMyBatis
0 likes · 34 min read
Master MyBatis Dynamic SQL: Eliminate XML Mappers and Supercharge CRUD
macrozheng
macrozheng
Dec 21, 2020 · Backend Development

Boost Your Java Backend: Master MyBatis Generator for Automatic CRUD Code

This article explains how to integrate MyBatis Generator into a Spring Boot project, configure it to generate entity classes, mapper XML and CRUD methods, and extend its capabilities with custom comment generators, advanced queries, and one‑to‑many/one‑to‑one mappings, reducing manual coding effort.

CRUDMyBatisMyBatis Generator
0 likes · 20 min read
Boost Your Java Backend: Master MyBatis Generator for Automatic CRUD Code
Top Architect
Top Architect
Dec 16, 2020 · Backend Development

Integrating PageHelper with SpringBoot and MyBatis for Efficient Pagination

This article provides a comprehensive guide on integrating PageHelper with SpringBoot and MyBatis, covering development preparation, dependency configuration, basic and advanced usage patterns, code examples, and detailed explanations of pagination mechanisms, including PageParam design and MyBatis interceptor internals.

MyBatisSpringBootbackend
0 likes · 19 min read
Integrating PageHelper with SpringBoot and MyBatis for Efficient Pagination
Architect's Tech Stack
Architect's Tech Stack
Dec 16, 2020 · Databases

MyBatis Dynamic SQL Tutorial: Using if, choose, trim, foreach, and bind Tags with Code Examples

This article explains MyBatis dynamic SQL features—including if, choose, trim, foreach, and bind tags—by showing how to set up a Maven project, create a student table, write mapper methods, and run tests that demonstrate conditional queries, updates, inserts, batch operations, and database‑agnostic expressions.

Dynamic SQLMyBatisORM
0 likes · 19 min read
MyBatis Dynamic SQL Tutorial: Using if, choose, trim, foreach, and bind Tags with Code Examples
Selected Java Interview Questions
Selected Java Interview Questions
Dec 11, 2020 · Databases

Implementing MyBatis Streaming Queries in Spring: Concepts, API, and Three Practical Solutions

This article explains the concept of streaming queries, introduces MyBatis's Cursor interface, demonstrates how to use it in Spring MVC controllers, and provides three concrete solutions—using SqlSessionFactory, TransactionTemplate, and @Transactional—to keep the database connection open and avoid cursor‑closed errors.

CursorDatabaseMyBatis
0 likes · 7 min read
Implementing MyBatis Streaming Queries in Spring: Concepts, API, and Three Practical Solutions