Skip to content

Commit

Permalink
Fix query in CustomSelectExamples and missing table import in Queryin…
Browse files Browse the repository at this point in the history
…gExamples
  • Loading branch information
vnikolova committed Dec 4, 2024
1 parent 1425603 commit bde7ff5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ fun main() {
runCreateExamples()
runReadExamples()
runUpdateExamples()
runQueryingExamples()
runAliasExamples()
runCustomSelectExamples()
//runDeleteExamples()
runQueryingExamples()
runDeleteExamples()
}
}

Expand Down Expand Up @@ -79,7 +79,7 @@ fun runDeleteExamples() {

fun runQueryingExamples() {
val queryingExamples = QueryingExamples()
queryingExamples.aggregateAndSort()
queryingExamples.useWhereConditions()
}

fun runAliasExamples() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class CustomSelectExamples {
.selectAll()
.withDistinct()
.where { StarWarsFilmsTable.sequelId less 8 }
.groupBy(StarWarsFilmsTable.director)
.groupBy(StarWarsFilmsTable.id)

val queryWithHint = originalQuery
.indexHint("FORCE INDEX (PRIMARY)")
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package org.example.examples

import org.example.tables.*
import org.example.tables.ActorsTable
import org.example.tables.StarWarsFilmsTable
import org.jetbrains.exposed.sql.SortOrder
import org.jetbrains.exposed.sql.andWhere
import org.jetbrains.exposed.sql.anyFrom
Expand Down

0 comments on commit bde7ff5

Please sign in to comment.