Hello! I have two questions concerning choosing\creation time of querry plan regaring default_statistic_target parameter. I noticed that querry plan creation time increases when default_statistic_target is more than 1000. It reaches 14 sec for database without any load when default_statistic_target = 10 000. I wonder: 1) Is such behavior considered normal? If it is, where I can get documentation regulating this?
It is normal that increasing default_statistic_target will increase planning time. Increasing it to 14 seconds is undesirable, of course, but without seeing the query it is hard to say more than that. This could be a bug which leads to pathologically slow planning in some cases, or it could be that your query is just a monster query that is difficult to plan.
2) Is there any way to limit querry plan creation time?