SqlSelect

case
class SqlSelect(context: Context, withs: List[WithRef], table: TableExpr, cols: List[SqlColumn], joins: List[SqlJoin], wheres: List[Predicate], orders: List[OrderSelection[_]], offset: Option[Int], limit: Option[Int], distinct: List[SqlColumn], oneToOne: Boolean, predicate: Boolean) extends SqlQuery

Representation of an SQL SELECT

Companion
object
trait SqlQuery
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Concrete methods

def addFilterOrderByOffsetLimit(filter: Option[(Predicate, List[SqlJoin])], orderBy: Option[(List[OrderSelection[_]], List[SqlJoin])], offset0: Option[Int], limit0: Option[Int], predIsOneToOne: Boolean, parentConstraints: List[(SqlColumn, SqlColumn)]): Option[SqlSelect]

Add WHERE, ORDER BY and LIMIT to this query

Add WHERE, ORDER BY and LIMIT to this query

def codecs: List[(Boolean, Codec)]
def contains(other: ColumnOwner): Boolean
def directlyOwns(col: SqlColumn): Boolean
def isDistinct: Boolean
override
def isSameOwner(other: ColumnOwner): Boolean
Definition Classes
def isUnion: Boolean
def needsCollation(col: SqlColumn): Boolean

Does the given column need collation?

Does the given column need collation?

def nest(parentContext: Context, extraCols: List[SqlColumn], oneToOne: Boolean, lateral: Boolean): SqlSelect

Nest this query as a subobject in the enclosing parentContext

Nest this query as a subobject in the enclosing parentContext

def owns(col: SqlColumn): Boolean

If the from clause of this query is a subquery, convert it to a common table expression

If the from clause of this query is a subquery, convert it to a common table expression

Yields a copy of this select with all occurences of from replaced by to

Yields a copy of this select with all occurences of from replaced by to

def syntheticName(suffix: String): String

Yield a name for this select derived from any names associated with its from clauses or joins

Yield a name for this select derived from any names associated with its from clauses or joins

Render this SqlSelect as a Fragment

Render this SqlSelect as a Fragment

def toSubquery(name: String, lateral: Boolean): SqlSelect

Yields an equivalent query encapsulating this query as a subquery

Yields an equivalent query encapsulating this query as a subquery

def toWithQuery(name: String, refName: Option[String]): SqlSelect

Yields an equivalent query encapsulating this query as a common table expression

Yields an equivalent query encapsulating this query as a common table expression

def withContext(context: Context, extraCols: List[SqlColumn], extraJoins: List[SqlJoin]): SqlSelect

This query in the given context

This query in the given context

Inherited methods

def asSelects: List[SqlSelect]

Yields a collection of SqlSelects which when combined as a union are equivalent to this query

Yields a collection of SqlSelects which when combined as a union are equivalent to this query

Inherited from
SqlQuery
def debugShow: String
Inherited from
ColumnOwner
def nameOption: Option[String]

The name, if any, of this ColumnOwner

The name, if any, of this ColumnOwner

Inherited from
ColumnOwner
def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product

Concrete fields

val orderCols: List[SqlColumn]

The columns, if any, on which this select is ordered

The columns, if any, on which this select is ordered