Skip to content

Commit

Permalink
fix float format in sql
Browse files Browse the repository at this point in the history
  • Loading branch information
yaacov committed Oct 7, 2018
1 parent 51890f0 commit 3f938b1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/tsl/squirrel_walk.go
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ func SquirrelWalk(n Node) (s sq.Sqlizer, err error) {
case IdentOp:
s = sq.Expr(n.Left.(string))
case NumberOp:
f := strconv.FormatFloat(n.Left.(float64), 'f', -1, 64)
f := strconv.FormatFloat(n.Left.(float64), 'g', -1, 64)
s = sq.Expr(f)
case StringOp:
s = sq.Expr(n.Left.(string))
Expand Down

0 comments on commit 3f938b1

Please sign in to comment.