com.softinio.duck4s.algebra.ParameterBinder
See theParameterBinder companion object
Type class for binding individual parameters to prepared statements.
This type class provides a way to bind individual parameter values to prepared statements at specific parameter indexes. Implementations are provided for common Scala types and Option types.
Type parameters
- T
-
the type of parameter value to bind
Attributes
- See also
-
BatchBinder for batch parameter binding
- Since
-
0.1.0
- Example
-
// Custom binder for a custom type case class UserId(value: Long) given ParameterBinder[UserId] with def bind( stmt: DuckDBPreparedStatement, index: Int, value: UserId ): Either[DuckDBError, Unit] = stmt.setLong(index, value.value).map(_ => ())
- Companion
- object
- Graph
-
- Supertypes
- Known subtypes
Members list
In this article