JPA is one of those areas of Java that people have problems with. It is sometimes refereed to as “Black magic”, where most of the time stuff works just fine, but other times it just starts doing something that make people go: “Why the heck is it doing this?”. Well most of the time it is due to lack of understanding of how things work and most often than not it is due to lack of reading and learning it properly.
So we started these tutorials some time ago and have now decided to get them together. In these tutorial we go by example, and try to cover as much as it is relevant for each bit and to create a solid foundation for the following tutorials.
It is expected some basic knowledge of SQL and relational databases, what an EJB is and where does it run and Unit Testing. An IDE setup and ready to go, a MySQL database and basic knowledge on how to use them will allow you to follow the Tutorials on your own machine is recommended.
- Getting Started with JPA 2 Tutorial
- Relationships – One To Many
- Relationships – Many To Many
- Queries with JPQL
- IDE : IntelliJ (Definitely our favorite) ; NetBeans
- Database : MySQL
- Build Automation Tool : Maven
- Database Tools : MySQL Workbench
- Application Server : Glassfish 18.104.22.168