O'Reilly logo

Pro JPA 2, Second Edition by Merrick Schincariol, Mike Keith

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 11

image

Advanced Queries

At this point, most of you will know enough about queries from what you have learned so far that you will likely not need any of the material from this chapter. In fact, roughly half of this chapter deals with using queries that will couple your application to a target database, so they should be used with some degree of planning and caution in any case.

We will start by going through the JPA support for native SQL queries and show how the results can be mapped to entities, non-entities, or simple data projection results. We will then move on to stored procedure queries and explain how a stored procedure can be invoked ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required