DM-1210: Invert buffering for czar in row-based result handling

Code review for DM-1210
This looks like unhealthy mix of `boost::format` and `stringstream`. Can you do it with `ostringstream` only?