class CompoundSelect[Q, R] extends Proxy[Q, R]

A SQL SELECT query, with ORDER BY, LIMIT, OFFSET, or UNION clauses

Linear Supertypes
Proxy[Q, R], Select[Q, R], Wrapped, DelegateQueryable[Q, Seq[R]], Query[Seq[R]], JoinOps[Select, Q, R], Joinable[Q, R], Aggregatable[Q], WithSqlExpr[Q], Renderable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CompoundSelect
  2. Proxy
  3. Select
  4. Wrapped
  5. DelegateQueryable
  6. Query
  7. JoinOps
  8. Joinable
  9. Aggregatable
  10. WithSqlExpr
  11. Renderable
  12. AnyRef
  13. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new CompoundSelect(lhs: SimpleSelect[Q, R], compoundOps: Seq[Op[Q, R]], orderBy: Seq[OrderBy], limit: Option[Int], offset: Option[Int])(implicit qr: Row[Q, R], dialect: DialectTypeMappers)

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def aggregate[E, V](f: (Proxy[Q]) => E)(implicit qr: Row[E, V]): Aggregate[E, V]

    Performs one or more aggregates in a single Select

    Performs one or more aggregates in a single Select

    Definition Classes
    ProxySelect
  5. def aggregateExpr[V](f: (Q) => (Context) => SqlStr)(implicit arg0: TypeMapper[V], qr: Row[Expr[V], V]): Expr[V]
    Definition Classes
    Proxy → Aggregatable
  6. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  7. def asc: Select[Q, R]

    Combined with sortBy to make the sort order ascending, translates into SQL ASC

    Combined with sortBy to make the sort order ascending, translates into SQL ASC

    Definition Classes
    CompoundSelectProxySelect
  8. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @HotSpotIntrinsicCandidate() @native()
  9. def compound0(op: String, other: Select[Q, R]): CompoundSelect[Q, R]
    Definition Classes
    CompoundSelectProxySelect
  10. val compoundOps: Seq[Op[Q, R]]
  11. def contains(other: Q): Expr[Boolean]

    Returns whether or not the Select on the left contains the other value on the right

    Returns whether or not the Select on the left contains the other value on the right

    Definition Classes
    Select
  12. def copy[Q, R](lhs: SimpleSelect[Q, R] = this.lhs, compoundOps: Seq[Op[Q, R]] = this.compoundOps, orderBy: Seq[OrderBy] = this.orderBy, limit: Option[Int] = this.limit, offset: Option[Int] = this.offset)(implicit qr: Row[Q, R]): CompoundSelect[Q, R]
    Attributes
    protected
  13. def crossJoin[Q2, R2, QF, RF](other: Joinable[Q2, R2])(implicit ja: JoinAppend[Q, Q2, QF, RF]): Select[QF, RF]

    Performs a CROSS JOIN, which is an INNER JOIN but without the ON clause

    Performs a CROSS JOIN, which is an INNER JOIN but without the ON clause

    Definition Classes
    JoinOps
  14. def crossJoin[Q2, R2](): Mapper[Q, Q2, R, R2]

    Version of crossJoin meant for usage in for-comprehensions

    Version of crossJoin meant for usage in for-comprehensions

    Definition Classes
    Joinable
  15. def desc: Select[Q, R]

    Combined with sortBy to make the sort order descending, translates into SQL DESC

    Combined with sortBy to make the sort order descending, translates into SQL DESC

    Definition Classes
    CompoundSelectProxySelect
  16. implicit val dialect: DialectTypeMappers
    Definition Classes
    CompoundSelectSelect
  17. def distinct: Select[Q, R]

    Causes this Select to ignore duplicate rows, translates into SQL SELECT DISTINCT

    Causes this Select to ignore duplicate rows, translates into SQL SELECT DISTINCT

    Definition Classes
    Select
  18. def drop(n: Int): Select[Q, R]

    Drops the first n rows from this Select.

    Drops the first n rows from this Select. Like when used in Scala collections, if called multiple times the dropped rows add up

    Definition Classes
    CompoundSelectProxySelect
  19. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  20. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  21. def except(other: Select[Q, R]): Select[Q, R]

    Subtracts the other from this Select, returning only rows present this but absent in other, and removing duplicates.

    Subtracts the other from this Select, returning only rows present this but absent in other, and removing duplicates. Translates into SQL EXCEPT

    Definition Classes
    Select
  22. def expr: Q
    Attributes
    protected
    Definition Classes
    CompoundSelectProxy → WithSqlExpr
  23. def filter(f: (Q) => Expr[Boolean]): Select[Q, R]

    Filters this Select with the given predicate, translates into a SQL WHERE clause

    Filters this Select with the given predicate, translates into a SQL WHERE clause

    Definition Classes
    CompoundSelectProxySelect
  24. def filterIf(cond: Boolean)(f: (Q) => Expr[Boolean]): Select[Q, R]

    Filters this Select with the given predicate, if cond evaluates to true

    Filters this Select with the given predicate, if cond evaluates to true

    Definition Classes
    ProxySelect
  25. def filterOpt[T](option: Option[T])(f: (Q, T) => Expr[Boolean]): Select[Q, R]

    Filters this Select with the given predicate consuming provided option as a part of predicate's input, if this option is Some[T]

    Filters this Select with the given predicate consuming provided option as a part of predicate's input, if this option is Some[T]

    Definition Classes
    ProxySelect
  26. def flatMap[Q2, R2](f: (Q) => Rhs[Q2, R2])(implicit qr: Row[Q2, R2]): Select[Q2, R2]

    Performs an implicit JOIN between this Select and the one returned by the callback function f

    Performs an implicit JOIN between this Select and the one returned by the callback function f

    Definition Classes
    ProxySelect
  27. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @HotSpotIntrinsicCandidate() @native()
  28. def groupBy[K, V, R2, R3](groupKey: (Q) => K)(groupAggregate: (Proxy[Q]) => V)(implicit qrk: Row[K, R2], qrv: Row[V, R3]): Select[(K, V), (R2, R3)]

    Translates into a SQL GROUP BY, takes a function specifying the group-key and a function specifying the group-aggregate.

    Translates into a SQL GROUP BY, takes a function specifying the group-key and a function specifying the group-aggregate.

    Definition Classes
    ProxySelect
  29. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @HotSpotIntrinsicCandidate() @native()
  30. def head: Single[R]

    Shorthand for .take(1).single:

    Shorthand for .take(1).single:

    1. If the query returns a single row, this returns it as a single value of type R 2. If the query returns multiple rows, returns the first as a single value of type R and discards the rest 3. If the query returns zero rows, throws an exception.

    Definition Classes
    Select
  31. def intersect(other: Select[Q, R]): Select[Q, R]

    Intersects the result rows of this Select with another, preserving only rows present in both this and the other and removing duplicates.

    Intersects the result rows of this Select with another, preserving only rows present in both this and the other and removing duplicates. Translates into SQL INTERSECT

    Definition Classes
    Select
  32. def isEmpty: Expr[Boolean]

    Returns whether or not the Select on the left is empty with zero elements

    Returns whether or not the Select on the left is empty with zero elements

    Definition Classes
    Select
  33. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  34. def join[Q2, R2, QF, RF](other: Joinable[Q2, R2])(on: (Q, Q2) => Expr[Boolean])(implicit ja: JoinAppend[Q, Q2, QF, RF]): Select[QF, RF]

    Performs a JOIN/INNER JOIN on the given other, typically a Table or Select.

    Performs a JOIN/INNER JOIN on the given other, typically a Table or Select.

    Definition Classes
    JoinOps
  35. def join[Q2, R2](on: (Q) => Expr[Boolean]): Mapper[Q, Q2, R, R2]

    Version of join meant for usage in for-comprehensions

    Version of join meant for usage in for-comprehensions

    Definition Classes
    Joinable
  36. def join0[Q2, R2, QF, RF](prefix: String, other: Joinable[Q2, R2], on: Option[(Q, Q2) => Expr[Boolean]])(implicit ja: JoinAppend[Q, Q2, QF, RF]): Select[QF, RF]
    Attributes
    protected
    Definition Classes
    ProxyJoinOps
  37. def joinInfo[Q2, R2](joinPrefix: String, other: Joinable[Q2, R2], on: Option[(Q, Q2) => Expr[Boolean]]): (Seq[Join], Q2)
    Attributes
    protected
    Definition Classes
    JoinOps
  38. def joinableToFromExpr: (From, Q)
    Attributes
    protected
    Definition Classes
    SelectJoinable
  39. def leftJoin[Q2, R2](other: Joinable[Q2, R2])(on: (Q, Q2) => Expr[Boolean])(implicit joinQr: Row[Q2, R2]): Select[(Q, JoinNullable[Q2]), (R, Option[R2])]

    Performs a LEFT JOIN on the given other, typically a Table or Select.

    Performs a LEFT JOIN on the given other, typically a Table or Select.

    Definition Classes
    ProxySelect
  40. def leftJoin[Q2, R2](on: (Q) => Expr[Boolean]): NullableMapper[Q, Q2, R, R2]

    Version of leftJoin meant for usage in for-comprehensions

    Version of leftJoin meant for usage in for-comprehensions

    Definition Classes
    Joinable
  41. val lhs: SimpleSelect[Q, R]
  42. val limit: Option[Int]
  43. def map[Q2, R2](f: (Q) => Q2)(implicit qr2: Row[Q2, R2]): Select[Q2, R2]

    Transforms the return value of this Select with the given function

    Transforms the return value of this Select with the given function

    Definition Classes
    CompoundSelectProxySelect
  44. def mapAggregate[Q2, R2](f: (Q, Proxy[Q]) => Q2)(implicit qr: Row[Q2, R2]): Select[Q2, R2]

    Performs a .map which additionally provides a Aggregatable.Proxy that allows you to perform aggregate functions.

    Performs a .map which additionally provides a Aggregatable.Proxy that allows you to perform aggregate functions.

    Definition Classes
    ProxySelect
  45. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  46. def newCompoundSelect[Q, R](lhs: SimpleSelect[Q, R], compoundOps: Seq[Op[Q, R]], orderBy: Seq[OrderBy], limit: Option[Int], offset: Option[Int])(implicit qr: Row[Q, R], dialect: DialectTypeMappers): CompoundSelect[Q, R]
    Attributes
    protected
    Definition Classes
    Select
  47. def newSimpleSelect[Q, R](expr: Q, exprPrefix: Option[(Context) => SqlStr], exprSuffix: Option[(Context) => SqlStr], preserveAll: Boolean, from: Seq[From], joins: Seq[Join], where: Seq[Expr[_]], groupBy0: Option[GroupBy])(implicit qr: Row[Q, R], dialect: DialectTypeMappers): SimpleSelect[Q, R]
    Attributes
    protected
    Definition Classes
    Select
  48. def nonEmpty: Expr[Boolean]

    Returns whether or not the Select on the left is nonempty with one or more elements

    Returns whether or not the Select on the left is nonempty with one or more elements

    Definition Classes
    Select
  49. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @HotSpotIntrinsicCandidate() @native()
  50. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @HotSpotIntrinsicCandidate() @native()
  51. def nullsFirst: Select[Q, R]

    Combined with sortBy to configure handling of nulls, translates into SQL NULLS FIRST

    Combined with sortBy to configure handling of nulls, translates into SQL NULLS FIRST

    Definition Classes
    CompoundSelectProxySelect
  52. def nullsLast: Select[Q, R]

    Combined with sortBy to configure handling of nulls, translates into SQL NULLS LAST

    Combined with sortBy to configure handling of nulls, translates into SQL NULLS LAST

    Definition Classes
    CompoundSelectProxySelect
  53. val offset: Option[Int]
  54. val orderBy: Seq[OrderBy]
  55. def outerJoin[Q2, R2](other: Joinable[Q2, R2])(on: (Q, Q2) => Expr[Boolean])(implicit joinQr: Row[Q2, R2]): Select[(JoinNullable[Q], JoinNullable[Q2]), (Option[R], Option[R2])]

    Performs a OUTER JOIN on the given other, typically a Table or Select.

    Performs a OUTER JOIN on the given other, typically a Table or Select.

    Definition Classes
    ProxySelect
  56. implicit val qr: Row[Q, R]
    Definition Classes
    CompoundSelectProxySelectDelegateQueryable
  57. def queryConstruct(args: ResultSetIterator): Seq[R]
    Attributes
    protected
    Definition Classes
    ProxyQuery
  58. def queryGetGeneratedKeys: Option[Row[_, _]]
    Attributes
    protected
    Definition Classes
    Query
  59. def queryIsExecuteUpdate: Boolean
    Attributes
    protected
    Definition Classes
    DelegateQueryableQuery
  60. def queryIsSingleRow: Boolean
    Attributes
    protected
    Definition Classes
    SelectDelegateQueryableQuery
  61. def queryWalkExprs(): Seq[Expr[_]]
    Attributes
    protected
    Definition Classes
    DelegateQueryableQuery
  62. def queryWalkLabels(): Seq[List[String]]
    Attributes
    protected
    Definition Classes
    DelegateQueryableQuery
  63. def rightJoin[Q2, R2](other: Joinable[Q2, R2])(on: (Q, Q2) => Expr[Boolean])(implicit joinQr: Row[Q2, R2]): Select[(JoinNullable[Q], Q2), (Option[R], R2)]

    Performs a RIGHT JOIN on the given other, typically a Table or Select.

    Performs a RIGHT JOIN on the given other, typically a Table or Select.

    Definition Classes
    ProxySelect
  64. def selectExprAliases(prevContext: Context): Seq[(Identity, SqlStr)]
    Attributes
    protected
    Definition Classes
    CompoundSelectProxyWrapped
  65. def selectRenderer(prevContext: Context): Renderer
    Attributes
    protected
    Definition Classes
    CompoundSelectProxyWrapped
  66. def selectToSimpleSelect(): SimpleSelect[Q, R]
    Attributes
    protected
    Definition Classes
    CompoundSelectProxySelect
  67. def selectWithExprPrefix(preserveAll: Boolean, s: (Context) => SqlStr): Select[Q, R]
    Attributes
    protected
    Definition Classes
    ProxySelect
  68. def selectWithExprSuffix(preserveAll: Boolean, s: (Context) => SqlStr): Select[Q, R]
    Attributes
    protected
    Definition Classes
    ProxySelect
  69. def single: Single[R]

    Asserts that this query returns exactly one row, and returns a single value of type R rather than a Seq[R].

    Asserts that this query returns exactly one row, and returns a single value of type R rather than a Seq[R]. Throws an exception if zero or multiple rows are returned.

    Definition Classes
    Select
  70. def sortBy(f: (Q) => Expr[_]): Select[Q, R]

    Sorts this Select via the given expression.

    Sorts this Select via the given expression. Translates into a SQL ORDER BY clause. Can be called more than once to sort on multiple columns, with the last call to sortBy taking priority. Can be followed by asc, desc, nullsFirst or nullsLast to configure the sort order

    Definition Classes
    CompoundSelectProxySelect
  71. def subquery: SimpleSelect[Q, R]

    Forces this Select to be treated as a subquery that any further operations will operate on, rather than having some operations flattened out into clauses in this Select

    Forces this Select to be treated as a subquery that any further operations will operate on, rather than having some operations flattened out into clauses in this Select

    Definition Classes
    Select
  72. def subqueryRef(implicit qr: Row[Q, R]): SubqueryRef
    Attributes
    protected
    Definition Classes
    Select
  73. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  74. def take(n: Int): Select[Q, R]

    Only returns the first n rows from this Select.

    Only returns the first n rows from this Select. Like when used in Scala collections, if called multiple times only the smallest value of n takes effect

    Definition Classes
    CompoundSelectProxySelect
  75. def toExpr(implicit mt: TypeMapper[R]): Expr[R]

    Converts this Select into an Expr, assuming it returns a single row and a single column.

    Converts this Select into an Expr, assuming it returns a single row and a single column. Note that if this returns multiple rows, behavior is database-specific, with some like Sqlite simply taking the first row while others like Postgres/MySql throwing exceptions

    Definition Classes
    Select
  76. def toString(): String
    Definition Classes
    AnyRef → Any
  77. def union(other: Select[Q, R]): Select[Q, R]

    Concatenates the result rows of this Select with another and removes duplicate rows; translates into SQL UNION

    Concatenates the result rows of this Select with another and removes duplicate rows; translates into SQL UNION

    Definition Classes
    Select
  78. def unionAll(other: Select[Q, R]): Select[Q, R]

    Concatenates the result rows of this Select with another; translates into SQL UNION ALL

    Concatenates the result rows of this Select with another; translates into SQL UNION ALL

    Definition Classes
    Select
  79. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  80. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  81. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  82. def withFilter(f: (Q) => Expr[Boolean]): Select[Q, R]

    Alias for filter

    Alias for filter

    Definition Classes
    Select

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

    (Since version 9)

Inherited from Proxy[Q, R]

Inherited from Select[Q, R]

Inherited from Wrapped

Inherited from DelegateQueryable[Q, Seq[R]]

Inherited from Query[Seq[R]]

Inherited from JoinOps[Select, Q, R]

Inherited from Joinable[Q, R]

Inherited from Aggregatable[Q]

Inherited from WithSqlExpr[Q]

Inherited from Renderable

Inherited from AnyRef

Inherited from Any

Ungrouped