Added support for cursor.messages property (optional dbapi interface extension)
Exception creation refactored, code extracted into separate function
In theory, python db api requires to send warning when optional extension is used, however I didn't see anyone else sending them and it looks weird to me
Warning implemented, but commented