in exposed-r2dbc/src/main/kotlin/org/jetbrains/exposed/v1/r2dbc/mappers/DateTimeMySqlTypeMapper.kt [19:37]
override fun setValue(
statement: Statement,
dialect: DatabaseDialect,
typeMapping: R2dbcTypeMapping,
columnType: IColumnType<*>,
value: Any?,
index: Int
): Boolean {
if (columnType !is IDateColumnType) return false
if (value == null) return false
// this conversion is required to retain MySQL precision
if (value is java.sql.Timestamp && dialect is MysqlDialect) {
statement.bind(index - 1, value.toString())
return true
}
return false
}