Added ORM functionality