You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Dialect.PostgreSql, when using the string concatenation operator (||), extra whitespace is inserted.
val res =SqlFormatter
.of(Dialect.PostgreSql)
.format("select aa || bb from zzz")
println(res)
// select// aa | | bb// ^// from// zzz
If you run dialectConfig.plusOperators("||"), no extra whitespace will be inserted.
val res =SqlFormatter
.of(Dialect.PostgreSql)
.extend { dialectConfig -> dialectConfig.plusOperators("||") }
.format("select aa || bb from zzz")
println(res)
// select// aa || bb// from// zzz
Similar whitespace will be inserted in Dialect.N1ql and Dialect.TSql.
I can't judge whether the response is appropriate, but after applying the following patch, plusOperators("||") is no longer needed.
In Dialect.PostgreSql, when using the string concatenation operator (||), extra whitespace is inserted.
If you run
dialectConfig.plusOperators("||")
, no extra whitespace will be inserted.Similar whitespace will be inserted in Dialect.N1ql and Dialect.TSql.
I can't judge whether the response is appropriate, but after applying the following patch,
plusOperators("||")
is no longer needed.The text was updated successfully, but these errors were encountered: