redesign of Sql from Connection to DataSource