Skip to content

Commit

Permalink
spanner/spannertest: handle returning DATE values through RPC interface
Browse files Browse the repository at this point in the history
The mapping to the correct Spanner type code was overlooked.

Change-Id: I9118caf02e43fcdaa98ca42f90deb0c931fcc41e
Reviewed-on: https://code-review.googlesource.com/c/gocloud/+/44110
Reviewed-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Knut Olav Løite <koloite@gmail.com>
  • Loading branch information
dsymonds committed Aug 16, 2019
1 parent 67ee51a commit 4093776
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions spanner/spannertest/inmem.go
Original file line number Diff line number Diff line change
Expand Up @@ -678,6 +678,8 @@ func spannerTypeFromType(typ spansql.Type) (*spannerpb.Type, error) {
code = spannerpb.TypeCode_STRING
case spansql.Bytes:
code = spannerpb.TypeCode_BYTES
case spansql.Date:
code = spannerpb.TypeCode_DATE
}
st := &spannerpb.Type{Code: code}
if typ.Array {
Expand Down

0 comments on commit 4093776

Please sign in to comment.