Skip to content

Instantly share code, notes, and snippets.

@barsbek
Created March 19, 2018 14:16
Show Gist options
  • Save barsbek/fc91bd6894cb8ad0ac5ea101cfcb87b5 to your computer and use it in GitHub Desktop.
Save barsbek/fc91bd6894cb8ad0ac5ea101cfcb87b5 to your computer and use it in GitHub Desktop.
postgresql: access preceding sub-selects in from clause
select * from t1, lateral (select * from t2 where t2.id = t1.id);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment