From adab090c1a1f224f55b67fa719130760e3762c64 Mon Sep 17 00:00:00 2001 From: vince Date: Sun, 25 Oct 2020 01:37:58 +0800 Subject: [PATCH 1/2] fix typo --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 907a03ed..00bf8d0a 100644 --- a/README.md +++ b/README.md @@ -265,7 +265,7 @@ object Employees : Table("t_employee") { > Naming Strategy: It's highly recommended to name your entity classes by singular nouns, name table objects by plurals (eg. Employee/Employees, Department/Departments). -Now that column bindings are configured, so we can use [sequence APIs](#Entity-Sequence-APIs) to perform many operations on entities. Let's add two extension properties for `Database` first. These properties return new created sequence objects via `sequenceOf` and they can help use improve the readability of the code: +Now that column bindings are configured, so we can use [sequence APIs](#Entity-Sequence-APIs) to perform many operations on entities. Let's add two extension properties for `Database` first. These properties return new created sequence objects via `sequenceOf` and they can help us improve the readability of the code: ```kotlin val Database.departments get() = this.sequenceOf(Departments) From 1471f9668e8ee989311d404fee8036d3a15f8165 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B5=8A=E9=85=92?= Date: Sun, 15 Nov 2020 00:21:28 +0800 Subject: [PATCH 2/2] fix table not containing schema in insert method --- .../src/main/kotlin/org/ktorm/expression/SqlFormatter.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ktorm-core/src/main/kotlin/org/ktorm/expression/SqlFormatter.kt b/ktorm-core/src/main/kotlin/org/ktorm/expression/SqlFormatter.kt index 36190094..d6fc678d 100644 --- a/ktorm-core/src/main/kotlin/org/ktorm/expression/SqlFormatter.kt +++ b/ktorm-core/src/main/kotlin/org/ktorm/expression/SqlFormatter.kt @@ -535,7 +535,8 @@ public abstract class SqlFormatter( override fun visitInsert(expr: InsertExpression): InsertExpression { writeKeyword("insert into ") - write("${expr.table.name.quoted} (") + visitTable(expr.table) + write("(") for ((i, assignment) in expr.assignments.withIndex()) { if (i > 0) write(", ") checkColumnName(assignment.column.name)