[06/09/2013-10:30:39.380] ERROR - APPLICATION <module>(<type 'exceptions.UnicodeEncodeError'>, UnicodeEncodeError('ascii', u"INSERT INTO APPLI.ALERT (ID_ALERT,MESSAGE,TYPE_ALERT) values(1617.0,q'[Les coordonn\xe9es ne sont pas correctes\n]',3)", 94, 95, 'ordinal not in range(128)'))
try: msg=open("myFile.log", 'r') a=msg.read(20) strInsert = "INSERT INTO APPLI.ALERT(ID_ALERT,MESSAGE,TYPE_ALERT) values(1625.0,'"+a.replace('\"','').decode('utf-8')+"',3)" logger_module.debug(str(strInsert)) SdeExecuteSQL(CONNEXION_FILE,strInsert ) except: python_error_handler()
Solved! Go to Solution.