Split ODM and ORM specific query types