public class

Select

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

Class Overview

A simple SQL SELECT statement

Summary

Fields
public final Dialect dialect
Public Constructors
Select(Dialect dialect)
Public Methods
LockMode getLockMode()
This method is deprecated. Instead use getLockOptions
LockOptions getLockOptions()
Get the current lock options
Select setComment(String comment)
Select setFromClause(String tableName, String alias)
Select setFromClause(String fromClause)
Sets the fromClause.
Select setGroupByClause(String groupByClause)
Select setLockMode(LockMode lockMode)
This method is deprecated. Instead use setLockOptions
Select setLockOptions(LockOptions lockOptions)
Set the lock options
Select setOrderByClause(String orderByClause)
Select setOuterJoins(String outerJoinsAfterFrom, String outerJoinsAfterWhere)
Select setSelectClause(String selectClause)
Sets the selectClause.
Select setWhereClause(String whereClause)
Sets the whereClause.
String toStatementString()
Construct an SQL SELECT statement from the given clauses
[Expand]
Inherited Methods
From class java.lang.Object

Fields

public final Dialect dialect

Public Constructors

public Select (Dialect dialect)

Public Methods

public LockMode getLockMode ()

This method is deprecated.
Instead use getLockOptions

Get the current lock mode

Returns
  • LockMode

public LockOptions getLockOptions ()

Get the current lock options

Returns
  • LockOptions

public Select setComment (String comment)

public Select setFromClause (String tableName, String alias)

public Select setFromClause (String fromClause)

Sets the fromClause.

Parameters
fromClause The fromClause to set

public Select setGroupByClause (String groupByClause)

public Select setLockMode (LockMode lockMode)

This method is deprecated.
Instead use setLockOptions

Set the lock mode

Returns
  • this object

public Select setLockOptions (LockOptions lockOptions)

Set the lock options

Returns
  • this object

public Select setOrderByClause (String orderByClause)

public Select setOuterJoins (String outerJoinsAfterFrom, String outerJoinsAfterWhere)

public Select setSelectClause (String selectClause)

Sets the selectClause.

Parameters
selectClause The selectClause to set

public Select setWhereClause (String whereClause)

Sets the whereClause.

Parameters
whereClause The whereClause to set

public String toStatementString ()

Construct an SQL SELECT statement from the given clauses