Refactor queries, add DBLib
23 errors to go...