revert changes for processing nulls

This commit is contained in:
Stephanie You
2023-11-06 11:46:14 -08:00
parent eec5a2d433
commit b13f74253f
2 changed files with 2 additions and 9 deletions

View File

@@ -761,13 +761,6 @@ func NameAndTypeTransform(row sql.Row, rowOperationSchema sql.PrimaryKeySchema,
row = applyMapperToRow(row, rowOperationSchema, rdSchema, nameMapper)
for i, col := range rowOperationSchema.Schema {
if s, ok := row[i].(string); ok {
if strings.ToLower(s) == "null" {
row[i] = nil
continue
}
}
// Check if this a string that can be converted to a boolean
val, ok := detectAndConvertToBoolean(row[i], col.Type)
if ok {

View File

@@ -813,10 +813,10 @@ DELIM
[ "${lines[1]}" = "nothing to commit, working tree clean" ]
}
@test "import-create-tables: import null foreign key value" {
@test "import-create-tables: import null foreign key value does not violate constraint" {
cat <<DELIM > test.csv
id, state_id, data
1, NULL,poop
1, ,poop
DELIM
dolt sql <<SQL