Improve SQL limits auto-configuration (2)