Re: Assigning different Exception message

2006-10-12 Thread Peter Otten
Tor Erik Soenvisen wrote: > try: > self.cursor.execute(sql) > except AttributeError, e: > if e.message == "oracleDB instance has no attribute 'cursor'": > e.message = 'oracleDB.open() must be called before' + \ > '

Assigning different Exception message

2006-10-12 Thread Tor Erik Soenvisen
try: self.cursor.execute(sql) except AttributeError, e: if e.message == "oracleDB instance has no attribute 'cursor'": e.message = 'oracleDB.open() must be called before' + \ ' oracleDB.query()' raise At