Is there a way to get the update count resulting from a query without returning?

I would like to assert that a statement in a transaction updates only the number of rows I expect, and fail if that number is different. I can do it with result.length and returning() but that includes a ton of data I don't need.
Was this page helpful?