Merge pull request #766 from kuba--/fix-null

support null results
This commit is contained in:
Kuba Podgórski 2020-09-01 15:33:02 +02:00 committed by GitHub
commit 2d202d6aa3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 0 deletions

View file

@ -414,6 +414,10 @@ func pgWriteResult(w pg.QueryResultWriter, result interface{}) error {
}
return nil
case nil:
return nil
default:
return errors.Errorf("result type %T not yet supported", result)
}

View file

@ -127,6 +127,9 @@ func (s *SelectHandler) execMappingResult(ctx context.Context, mr *MappingResult
},
},
}
case nil:
result = pproto.ConstRowser{}
default:
return nil, fmt.Errorf("unsupported result type %T", res)
}