Crunchy Bridge delivers a fully managed cloud Postgres service available on multiple clouds so you can focus on your application,

Devious SQL: Run the Same Query Against Tables With Differing Columns

submited by
Style Pass
2021-06-08 15:30:07

Crunchy Bridge delivers a fully managed cloud Postgres service available on multiple clouds so you can focus on your application, not your database.

The Postgres Operator easily lets you automate your Postgres in Kubernetes, whether managing one database, or scaling to thousands.

Integrated high availability PostgreSQL solution for enterprises with always on requirements.

Hardened, secure, access controlled PostgreSQL to meet advanced security requirements.

We spend time day in, day out, answering the questions that matter and coming up with solutions that make the most sense. However, sometimes a question comes up that is just so darn…interesting that even if there are sensible solutions or workarounds, it still seems like a challenge just to take the request literally. Thus was born this blog series, Devious SQL.

The basic question/request that inspired this article (and in fact this entire series) was an internal question about whether one could devise a query that ran against a table/view that might have different columns depending on the PostgreSQL version. The specific details are unimportant here, but the basic idea was intriguing. So let's polish up our toolkits and see what we can accomplish.

Leave a Comment