mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-10-08 20:07:51 +00:00
Merge pull request #756 from niaow/postgres-sql-empty
Write empty column headers in postgres when there is no response
This commit is contained in:
commit
a872548b01
1 changed files with 8 additions and 0 deletions
|
|
@ -394,6 +394,14 @@ func (s *Server) handleStandard(ctx context.Context, proto Protocol, conn net.Co
|
|||
return errors.Wrap(err, "failed to send query error to client")
|
||||
}
|
||||
} else {
|
||||
if !qwriter.wroteHeaders {
|
||||
// The handler did not write headers.
|
||||
// Write back an empty set of headers.
|
||||
err = qwriter.WriteHeader()
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "sending empty column headers")
|
||||
}
|
||||
}
|
||||
// The query completed normally.
|
||||
// Notify the client of completion.
|
||||
msg, err = encoder.CommandComplete(qwriter.tag)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue