Solving errors in mysql adapter