Dba: WHERE A=x DISTINCT ON (B), with a composite index on (A, B, C)
WHERE A=x DISTINCT ON (B), with a composite index on (A, B, C)
I hope you found a solution that worked for you :)
The Content is licensed under (https://meta.stackexchange.com/help/licensing) CC BY-SA.
Attention! This video does always use the same license as the source!
Thanks to all those great people for their contributions!
(dba.stackexchange.com/users/310000/kadircancetin)kadircancetin
(dba.stackexchange.com/users/3684/erwin-brandstetter)Erwin Brandstetter
A special thanks goes out to the (dba.stackexchange.com/questions/342916/where-a-x-distinct-on-b-with-a-composite-index-on-a-b-c)Stackexchange community
I wish you all a wonderful day! Stay safe :)
If anything is off, please write me at peter D.O.T schneider A.T ois42.de
postgresql postgresql-performance greatest-n-per-group index query-performance