If I want a returning value when inserting a new row, I can do something like
val insertQuery = myTable returning myTable.map(_.id) += SomeData(someString)
How can I achieve the same effect when deleting?
I tried
val deleteQuery = myTable filter (_.id ===id) returning myTable.map(_.someColumn) delete
But apparently this does not compile.
I can resort to the for
comprehension but I wonder if there is a shorter way.