Today I Learned

A Hashrocket project

PostgreSQL Aggregate for Booleans

Today I learned that we can aggregate PostgreSQL boolean values with BOOL_OR or BOOL_AND so if we group a query we could return if any of those values are TRUE, or if all of those values are TRUE respectively.

Check this out

Looking for help? Hashrocket developers believe that data quality is as important as code quality. We enjoy all the challenges of relational databases, from finding the fastest index, to structuring data to fit the needs of an application. We're eager to share our experiences; check out PG Casts, our series of free PostgreSQL screencasts.