Introduction
It is difficult to imagine a complex software application that does not use some kind of structured and accessible data storage called a database. This is why any modern language implementation includes a framework that allows you to access the DB and create, read, update, and delete (CRUD) data in it. In Java, the Java Database Connectivity (JDBC) API provides access to any data source, from relational databases to spreadsheets and flat files.
Â
Based on this access, an application can manipulate data in the database directly, using database language (SQL, for example), or indirectly, using an Object-Relational Mapping (ORM) framework, which allows for the mapping of objects in memory to the tables in the database. The Java Persistence API (JPA) is the ORM specification for Java. When an ORM framework is used, the CRUD operations on the mapped Java objects are translated into the database language automatically. The list of the most popular ORM frameworks includes Apache Cayenne...