Sql and user connection