Postgres Articles
Read in-depth articles from our experts about Postgres.
Modeling Postgres Common Table Expressions and Window Functions with Rails and ActiveRecord

Over the course of my experience as a developer, I’ve often found that when things get complex - they get really complex. Often times the key to a solution isn’t finding the one thing that solves a problem, but rather the combination of different functionalities that ends up being the solution that works the best. In the case of one of our pro-bono projects, I had a particularly difficult problem that I needed to solve - and the solution that I arrived at involved a combination of Postgres’ Common Table Expressions, Window Functions, SearchLight, and Rails Query Scopes. What on earth was I trying to accomplish that could possibly elicit this witches brew of open source technologies? Simple: I needed to take user-supplied input, sanitize it, geocode it, then ensure that the result set did not contain duplicates. Each of the tools listed above contributed in some fashion to the working solution!

Continue Reading...

Hire Us!

Have questions? Ready to get started? Please contact us for a free project consultation and quote.