The first thought is, why are both parameters needed. Pass only returning_fields, move the calculation of `nvars` inside that function.

The second thought is, this whole code piece looks a little over-complicated. You don't need to define fetch_func and fetch_kwargs, and then make the call only of fetch_func is defined; just make the calls. You may need to rephrase the logic a little (like, take the block that is currently under "if fetch_func" out of the `if`, and put the rest of the function into an `else` on that if instead). An alternative to consider: `SQLCompiler` classes are inherited and overridden for different backends. You may want to spread some of the logic that way. 

A third thought: if `self.returning_fields and not  self.connection.features.can_return_multiple_fields`, shouldn't we raise an exception?