Class Select

java.lang.Object
org.hibernate.sql.Select

public class Select extends Object
A simple SQL SELECT statement
  • Field Details

    • dialect

      public final Dialect dialect
  • Constructor Details

    • Select

      public Select(Dialect dialect)
  • Method Details

    • toStatementString

      public String toStatementString()
      Construct an SQL SELECT statement from the given clauses
    • setFromClause

      public Select setFromClause(String fromClause)
      Sets the fromClause.
      Parameters:
      fromClause - The fromClause to set
    • setFromClause

      public Select setFromClause(String tableName, String alias)
    • setOrderByClause

      public Select setOrderByClause(String orderByClause)
    • setGroupByClause

      public Select setGroupByClause(String groupByClause)
    • setOuterJoins

      public Select setOuterJoins(String outerJoinsAfterFrom, String outerJoinsAfterWhere)
    • setSelectClause

      public Select setSelectClause(String selectClause)
      Sets the selectClause.
      Parameters:
      selectClause - The selectClause to set
    • setWhereClause

      public Select setWhereClause(String whereClause)
      Sets the whereClause.
      Parameters:
      whereClause - The whereClause to set
    • setComment

      public Select setComment(String comment)
    • getLockMode

      public LockMode getLockMode()
      Deprecated.
      Instead use getLockOptions
      Get the current lock mode
      Returns:
      LockMode
    • setLockMode

      public Select setLockMode(LockMode lockMode)
      Deprecated.
      Instead use setLockOptions
      Set the lock mode
      Parameters:
      lockMode -
      Returns:
      this object
    • getLockOptions

      public LockOptions getLockOptions()
      Get the current lock options
      Returns:
      LockOptions
    • setLockOptions

      public Select setLockOptions(LockOptions lockOptions)
      Set the lock options
      Parameters:
      lockOptions -
      Returns:
      this object