Use Query globally instead of session.