5
OrBaruk
7y

Why it is such a pain to scan nullable types on Golang database.sql

Now I have to chose between:

1- Using temporaty variable to hold the nullable value just to soon after check and set the zero value if it is null

2- Adding coalesce to my sql query for the zero values.

Did I mention that there are around 20 collumns that are nullable...

Comments
  • 1
    Golang is an “opinionated” programming language, in other words, when it works against your particular use case, “fuck you” and it laughs out.
Add Comment