donb
committed
on 20 Jan 10
Moved db-dependent queries to the right place.