sql connn can work in block