Open d6y opened 8 years ago
scala> messages.filter(_.id === 1L).result.statements
res10: Iterable[String] = List(select "sender", "content", "id" from "message" where "id" = 1)
scala> messages.filter(_.id === 1L.bind).result.statements
res11: Iterable[String] = List(select "sender", "content", "id" from "message" where "id" = ?)
Sometimes you see code examples containing
v.bind
. What isbind
, when would you use it?e.g.,
q0 = as.filter(_.id === 42.bind).length