Skip to content

Instantly share code, notes, and snippets.

@maxjustus
Created June 18, 2024 20:19
Show Gist options
  • Save maxjustus/79ddde3cddb3d0982f2a9c290c09ed77 to your computer and use it in GitHub Desktop.
Save maxjustus/79ddde3cddb3d0982f2a9c290c09ed77 to your computer and use it in GitHub Desktop.
-- uses pk assuming pk is y, z
select * from x where (y, z) in (select y, z from f);
-- does not use pk
select * from x where (y, z) in (select (y, z) from f);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment