/{go,integration-tests}: fix parse int with leading zero issue

This commit is contained in:
Dustin Brown
2021-07-07 11:21:54 -07:00
parent 3cb68a213c
commit fdd6d33293
2 changed files with 6 additions and 1 deletions
+6
View File
@@ -224,6 +224,12 @@ func leastPermissiveNumericType(strVal string, floatThreshold float64) (ti typei
if err != nil {
return typeinfo.UnknownType
}
// handle leading zero case
if strVal[0] == '0' {
return typeinfo.StringDefaultType
}
if ui <= math.MaxUint32 {
return typeinfo.Uint32Type
} else {
@@ -108,7 +108,6 @@ teardown() {
}
@test "import-create-tables: import data from csv and create the table different types" {
skip "unable to cast to uint64, parse error"
run dolt table import -c --pk=pk test people.csv
[ "$status" -eq 0 ]
[[ "$output" =~ "Import completed successfully." ]] || false