Skip to content

Commit

Permalink
address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
winkyao committed Jul 19, 2018
1 parent 876ad8e commit 6706842
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion table/tables/index.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ func (c *index) truncateIndexValuesIfNeeded(indexedValues []types.Datum) []types
rs := bytes.Runes(val)
truncateStr := string(rs[:ic.Length])
// truncate value and limit its length
v.SetBytes([]byte(truncateStr))
v.SetString(truncateStr)
}
} else {
if ic.Length != types.UnspecifiedLength && len(v.GetBytes()) > ic.Length {
Expand Down

0 comments on commit 6706842

Please sign in to comment.