From 667fe1d1137e90677236a325088ca5605c12f660 Mon Sep 17 00:00:00 2001 From: obabichevjb <166523824+obabichevjb@users.noreply.github.com> Date: Tue, 15 Oct 2024 15:49:53 +0200 Subject: [PATCH] Update exposed-core/src/main/kotlin/org/jetbrains/exposed/sql/Query.kt Co-authored-by: Jocelyne <38375996+joc-a@users.noreply.github.com> --- exposed-core/src/main/kotlin/org/jetbrains/exposed/sql/Query.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exposed-core/src/main/kotlin/org/jetbrains/exposed/sql/Query.kt b/exposed-core/src/main/kotlin/org/jetbrains/exposed/sql/Query.kt index 4a8fc4411b..d3dde1ac06 100644 --- a/exposed-core/src/main/kotlin/org/jetbrains/exposed/sql/Query.kt +++ b/exposed-core/src/main/kotlin/org/jetbrains/exposed/sql/Query.kt @@ -213,7 +213,7 @@ open class Query(override var set: FieldSet, where: Op?) : AbstractQuer append("DISTINCT ") } distinctOn?.let { columns -> - columns.appendTo(prefix = "DISTINCT ON (", postfix = ")") { +"${it.table.tableName}.${it.name}" } + columns.appendTo(prefix = "DISTINCT ON (", postfix = ") ") { +"${it.table.tableName}.${it.name}" } } set.realFields.appendTo { +it } }