© K. Siva Prasad Reddy 2017

K. Siva Prasad Reddy, Beginning Spring Boot 2, https://doi.org/10.1007/978-1-4842-2931-6_6

6. Working with MyBatis

K. Siva Prasad Reddy

(1)Hyderabad, India

MyBatis is an open source Java persistence framework that abstracts JDBC boilerplate code and provides a simple and easy-to-use API to interact with the database.

Unlike Hibernate, which is a full-blown ORM framework, MyBatis is a SQL mapping framework. It automates the process of populating the SQL resultset into Java objects and it persists data into tables by extracting the data from the Java objects.

This chapter covers how to use the Spring Boot MyBatis starter, how to execute database queries using MyBatis XML, and how to use annotation-based mappers.

Using the ...

Get Beginning Spring Boot 2: Applications and Microservices with the Spring Framework now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.