com.vladmihalcea.hibernate.query
Class SQLExtractor

java.lang.Object
  extended by com.vladmihalcea.hibernate.query.SQLExtractor
Direct Known Subclasses:
SQLExtractor

public class SQLExtractor
extends Object

The SQLExtractor allows you to extract the underlying SQL query generated by a JPQL or JPA Criteria API query.

For more details about how to use it, check out this article on vladmihalcea.com.

Since:
2.9.11
Author:
Vlad Mihalcea

Constructor Summary
protected SQLExtractor()
           
 
Method Summary
static String from(javax.persistence.Query query)
          Get the underlying SQL generated by the provided JPA query.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SQLExtractor

protected SQLExtractor()
Method Detail

from

public static String from(javax.persistence.Query query)
Get the underlying SQL generated by the provided JPA query.

Parameters:
query - JPA query
Returns:
the underlying SQL generated by the provided JPA query


Copyright © 2022. All rights reserved.