Each worker maintains its own state in a local copy of an sqlite database. It's named worker5.jnl, and is located in /var/spool/qube on linux and OSX, and it c:\programdata\pfx\qube in later versions of Windows.
it's likely that this is the corrupt database that's causing this error; the good news is that it's easy to fix.
$QBDIR/utils/upgrade_worker --reset
will produce output something like:
journal: /var/spool/qube/worker5.jnl
[Jan 4, 2011 13:50:54] jburk-17-mbpro : resetting the database.
removing journal: /var/spool/qube/worker5.jnl
Exec Database Error: no such table: tableversion(1)
SELECT version FROM tableversion
[Jan 4, 2011 13:50:54] jburk-17-mbpro : detecting current storage state...
[Jan 4, 2011 13:50:54] jburk-17-mbpro : constructing primary storage structure - version: 6
[Jan 4, 2011 13:50:55] jburk-17-mbpro : current storage version: 6