My friend Nathan and I published an article on the Cockroach Labs Blog:
In this article, we explain the type system we implemented for CockroachDB v1.0’s SQL dialect. It implements a large subset of PostgreSQL’s own dialect and performs inference using a bespoke unification algorithm.
Also available via the Wayback Machine.
So what do you think? Did I miss something? Is any part unclear? Leave your comments below.