Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Null support #8

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open

Added Null support #8

wants to merge 2 commits into from

Conversation

nikitajain1998
Copy link
Collaborator

Fixes #<issue_number_goes_here>

It's a good idea to open an issue first for discussion.

  • Tests pass
  • Appropriate changes to README are included in PR

singleRow[k] = s.Bool
}
}
}
fmt.Println("Single Row: ", singleRow)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leftover from debugging?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see that this is removed as part of another commit in this PR.

@@ -771,7 +772,11 @@ func parseRow(r *spanner.Row, colDDL map[string]string) (map[string]interface{},
}
return nil, errors.New("ValidationException", err, k)
}
if !s.IsNull() {
if s.IsNull() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This code is repeating for each type. You can move null handling outside switch statement and switch statement can handle non Null values

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants