Abstract
JPA (Java Persistence API) is the dedicated technology for accessing relational databases from inside Jakarta EE. Its aim is to provide a bridge between SQL tables and Java objects. This is a task that is far from simple for other than the most basic data schemes. The reason for this is that in relational database schemes there are associations between different tables: one row from one table may refer to one or many rows from another table or the other way around, and there could be references spanning three or more tables. And think of column-type conversions—a database may have different ideas about numbers, Boolean indicators, dates, and times compared to Java, and also null values in database tables require increased attention if used in table references and while converting to Java values.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2019 Peter Späth
About this chapter
Cite this chapter
Späth, P. (2019). Adding a Database with JPA. In: Beginning Jakarta EE. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-5079-2_6
Download citation
DOI: https://doi.org/10.1007/978-1-4842-5079-2_6
Published:
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-5078-5
Online ISBN: 978-1-4842-5079-2
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)