def _get_result_constructor(self):
if not self._values_list: <EOL><INDENT>return lambda rows: self.model._construct_instance(rows)<EOL><DEDENT>elif self._flat_values_list: <EOL><INDENT>return lambda row: row.popitem()[<NUM_LIT:1>]<EOL><DEDENT>else:<EOL><INDENT>return lambda row: self._get_row_value_list(self._only_fields, row)<EOL><DEDENT>
Returns a function that will be used to instantiate query results