fixed sql exec bug