We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This template isn't a strict requirement to open issues, but please try to provide as much information as possible.
Version: 4.6.0 Module: quill-jdbc-zio Database: postgresql
case class TestData(first: String) case class Test(id: String, data: Option[TestData]) implicit val encoder: JsonEncoder[TestData] = DeriveJsonEncoder.gen implicit val dbEncoder: MappedEncoding[TestData, JsonValue[TestData]] = MappedEncoding(JsonValue(_))
throw exception : org.postgresql.util.PSQLException: ERROR: column "data" is of type json but expression is of type character varying with this code
ctx.run(query[Test].insertValue(lift(Test("test", None)))).provideEnvironment(layer)
work fine with this code
ctx.run(query[Test].insertValue(lift(Test("test", Some(TestData("1")))))).provideEnvironment(layer)
work fine if use
implicit val dbOptionEncoder: MappedEncoding[Option[TestData], JsonValue[Option[TestData]]] = MappedEncoding(JsonValue(_))
instead of
implicit val dbEncoder: MappedEncoding[TestData, JsonValue[TestData]] = MappedEncoding(JsonValue(_))
but if use both code throw exception
The text was updated successfully, but these errors were encountered:
No branches or pull requests
This template isn't a strict requirement to open issues, but please try to provide as much information as possible.
Version: 4.6.0
Module: quill-jdbc-zio
Database: postgresql
throw exception : org.postgresql.util.PSQLException: ERROR: column "data" is of type json but expression is of type character varying
with this code
work fine with this code
work fine if use
instead of
but if use both code throw exception
The text was updated successfully, but these errors were encountered: