puting query to object for multi-db - wip