PgManager: log connection name with queries. BatchUpdateTool: handle some possible exceptions and try reconnect to database.
TESTS
=====
All test should work at least with Python 2.6, 2.7 and 3.2
How to test
-----------
1. Copy tests.conf.example to tests.conf and modify it so it points to your test database.
2. Create test tables using tests.sql
3. Run individual tests.