magnolify
magnolify copied to clipboard
Add support for JDBC reader/writer?
I am wondering if adding a type class for reading/writing from/to a SQL database via JDBC is being considered. It should be possible to implement something like this:
trait JdbcType[T] extends Converter[T, ResultSet, PreparedStatement]
and derive this converters for any case class. It could be seamlessly integrated with scio-jdbc
then.
Should be doable, although there might be some ugly casts esp for nested/repeated fields?