summaryrefslogtreecommitdiff
path: root/rows.go
diff options
context:
space:
mode:
Diffstat (limited to 'rows.go')
-rw-r--r--rows.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/rows.go b/rows.go
index ec94c64..ae7e01e 100644
--- a/rows.go
+++ b/rows.go
@@ -459,6 +459,13 @@ func (c *xlsxC) getValueFrom(f *File, d *xlsxSST, raw bool) (string, error) {
}
return f.formattedValue(c.S, c.V, raw), nil
default:
+ if isNum, precision := isNumeric(c.V); isNum && !raw {
+ if precision == 0 {
+ c.V = roundPrecision(c.V, 15)
+ } else {
+ c.V = roundPrecision(c.V, -1)
+ }
+ }
return f.formattedValue(c.S, c.V, raw), nil
}
}