refactored some error code into  a sql exception handler class print
method