Get the latest tech news

SQL queries don't start with SELECT (2019)


SQL queries don't start with SELECT

There are lots of other optimizations that database engines implement in practice that might make them run queries in a different order but there’s no room for that and honestly it’s not something I’m an expert on. dplyr in R also lets you use a different syntax for querying SQL databases like Postgres, MySQL and SQLite, which is also in a more logical order. I’m writing a blog post about this because when I found out the order I was SO SURPRISED that I’d never seen it written down that way before – it explains basically everything that I knew intuitively about why some queries are allowed and others aren’t.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of SQL

SQL

Photo of SQL queries

SQL queries

Photo of SELECT

SELECT

Related news:

News photo

Directus – real-time REST and GraphQL API of any SQL database

News photo

DOGE employees don't understand the basics of SQL

News photo

SQL pipe syntax available in public preview in BigQuery