Skip to content

Commit

Permalink
tweak subquery alias to match orderBy expression
Browse files Browse the repository at this point in the history
  • Loading branch information
jdfigure committed Dec 31, 2024
1 parent 9e096e0 commit fca2f7c
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ class TxMessageRecord(id: EntityID<Int>) : IntEntity(id) {

fun findByQueryForResults(txQueryParams: TxQueryParams) = transaction {
val query = findByQueryParams(txQueryParams, listOf(distId) + tableColSet)
.alias("subQuery") //create a subquery to delay sorting until after the distinct
.alias("tx_message") //create a subquery (aliased as tx_message) to delay sorting until after the distinct

Check failure on line 398 in service/src/main/kotlin/io/provenance/explorer/domain/entities/Transactions.kt

View workflow job for this annotation

GitHub Actions / ktlint

Missing space after //
.selectAll()
.orderBy(Pair(TxMessageTable.blockHeight, SortOrder.DESC))
.limit(txQueryParams.count, txQueryParams.offset.toLong())
Expand Down

0 comments on commit fca2f7c

Please sign in to comment.