- sql improvements