go-database-sql-tutorial icon indicating copy to clipboard operation
go-database-sql-tutorial copied to clipboard

Add a trick to handle null sql query results

Open liyuankui opened this issue 6 years ago • 1 comments

liyuankui avatar Jun 05 '18 02:06 liyuankui

This is interesting, but I don't know how to think about benefits and drawbacks, or other difference. For example, what happens if there is an error? I think we need a little more narrative to introduce this technique and explain why it wouldn't be an officially recommended technique. If this works fine, why did the database/sql authors create the built-in nullable types?

xaprb avatar Oct 29 '18 19:10 xaprb