change model to support strange replicated db's structure