Reg Me Please <regmeplease@xxxxxxxxx> writes: >> The OP's complaint is that we don't allow a variable of the query's own >> level, but AFAICT he's still not grasped the point that that leads to an >> indeterminate limit value ... > So it works, but it's not serious enough to be unlocked. You really don't have a clue what this is about, do you? Let me try to explain one more time. You propose allowing select ... from table1 join table2 on table1.x = table2.y limit table1.z Now this would be somewhat well-defined if there were only one row in table1, or if there were many rows but they all had the same value in column z. But what if that's not the case? If there are multiple possible values for z then the query is just not sensible. regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq