今天,在处理动态查询生成时,我发现mysql对于可以在一个联接中使用多少个表有一个硬性最大限制:
Today when playing around with dynamic query generation I discovered that mysql has a hard maximum limit of how many tables can be used in a join: 61.
我想知道PostgreSQL,PostgreSQL是否有类似的限制?
This lead me to wonder about PostgreSQL, does PostgreSQL have a analogous limit?
注意:我出于好奇而不是不必要地问这个。
推荐答案没有限制AFAIK。
查询优化器将切换到一旦超出了表的(可配置)限制,便采用了不同的算法。但这仅表示计划是以不同的方式计算的,并不是说语句将失败(尽管这可能不是最快的计划)。
The query optimizer will switch to a different algorithm once a (configurable) limit of tables has been exceeded.But that just means the plan is calculated in a different way, not that the statement will fail (it might not be the fastest plan though).
http:// www。 postgresql/docs/current/static/planner-optimizer.html
更多推荐
PostgreSQL对联接中的表数有限制吗?
发布评论