Persistence with JDBC

Abstract

The previous chapter introduced the Spring Framework’s integration with Java data-access frameworks. This chapter provides more detailed insight into Spring’s support for persistence using JDBC, covering the following topics:
  • How the JdbcTemplate class takes care of the boilerplate code you usually encounter and simplifies working with the JDBC API.

  • How to use the JdbcTemplate class to perform common database tasks, such as selecting, inserting, updating, and deleting data.

  • How to use a convenient base class for your data access objects (DAOs) that builds on the JdbcTemplate class.

  • How to use callbacks, which make performing more complex tasks easier.

  • How to use executable query objects, which allow you to work with database operations in a more object-oriented manner.

  • How to perform batch operations, working with large chunks of data in the form of large objects (LOBs), and obtaining native JDBC objects, while still leveraging the power of Spring’s data abstraction framework.

  • The features that are new in Spring 2.0, including the SimpleJdbcTemplate class, an even more lightweight template class for performing JDBC operations.

Keywords

Prepared Statement Member Instance Query Object Aggregate Function Public Class 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Interface 21, Bram Smeets, Seth Ladd 2007

Personalised recommendations